Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(nextcloud)!: Support server 29 and spreed 19 #1894

Merged
merged 5 commits into from
Apr 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .cspell/nextcloud.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ apppassword
bigfilechunking
boardname
bools
bruteforce
bulkupload
clearsky
configapi
Expand Down Expand Up @@ -34,12 +35,14 @@ nextcloud
nextcloud's
organisation
partlycloudy
pollinterval
productname
rainshowers
replyable
requesttoken
resharing
rgdnvw
roomid
setsip
shareapi
sharebymail
Expand Down
2 changes: 1 addition & 1 deletion external/nextcloud-notifications
Submodule nextcloud-notifications updated 92 files
+4 −3 .github/dependabot.yml
+2 −2 .github/workflows/command-compile.yml
+2 −2 .github/workflows/lint-eslint.yml
+7 −3 .github/workflows/lint-php-cs.yml
+14 −2 .github/workflows/lint-php.yml
+1 −1 .github/workflows/lint-stylelint.yml
+2 −2 .github/workflows/node.yml
+48 −7 .github/workflows/performance.yml
+4 −4 .github/workflows/phpunit-mysql.yml
+7 −5 .github/workflows/phpunit-oci.yml
+8 −6 .github/workflows/phpunit-pgsql.yml
+8 −6 .github/workflows/phpunit-sqlite.yml
+7 −3 .github/workflows/psalm.yml
+1 −1 .github/workflows/update-nextcloud-ocp-approve-merge.yml
+4 −4 .github/workflows/update-nextcloud-ocp.yml
+2 −2 appinfo/info.xml
+0 −2 appinfo/routes.php
+5 −3 composer.json
+194 −199 composer.lock
+2 −2 js/notifications-admin-settings.js
+1 −1 js/notifications-admin-settings.js.map
+1 −0 ...ons-data_image_svg_xml_3csvg_20xmlns_27http_www_w3_org_2000_svg_27_20width_2724_27_20height_2724_-b2e651.js
+0 −1 ...ons-data_image_svg_xml_base64_PCEtLSBUaGlzIGljb24gaXMgcGFydCBvZiBNYXRlcmlhbCBVSSBJY29ucy4gQ29weXJ-e25a52.js
+2 −2 js/notifications-main.js
+1 −1 js/notifications-main.js.map
+0 −3 ...ons-node_modules_moment_locale_sync_recursive_-src_NotificationsApp_vue-data_image_svg_xml_base64-ab95a3.js
+0 −1 ...node_modules_moment_locale_sync_recursive_-src_NotificationsApp_vue-data_image_svg_xml_base64-ab95a3.js.map
+0 −3 js/notifications-node_modules_nextcloud_dialogs_dist_chunks_index-c0bccfab_mjs.js
+0 −1 js/notifications-node_modules_nextcloud_dialogs_dist_chunks_index-c0bccfab_mjs.js.map
+3 −0 js/notifications-node_modules_nextcloud_dialogs_dist_chunks_index-clds-yO2_mjs.js
+0 −0 js/notifications-node_modules_nextcloud_dialogs_dist_chunks_index-clds-yO2_mjs.js.LICENSE.txt
+1 −0 js/notifications-node_modules_nextcloud_dialogs_dist_chunks_index-clds-yO2_mjs.js.map
+2 −2 js/notifications-settings.js
+1 −1 js/notifications-settings.js.map
+3 −0 js/notifications-src_NotificationsApp_vue.js
+0 −0 js/notifications-src_NotificationsApp_vue.js.LICENSE.txt
+1 −0 js/notifications-src_NotificationsApp_vue.js.map
+3 −0 ...ons-vendors-node_modules_nextcloud_auth_dist_index_js-node_modules_nextcloud_l10n_dist_index_mjs--c7a61b.js
+69 −0 ...node_modules_nextcloud_auth_dist_index_js-node_modules_nextcloud_l10n_dist_index_mjs--c7a61b.js.LICENSE.txt
+1 −0 ...vendors-node_modules_nextcloud_auth_dist_index_js-node_modules_nextcloud_l10n_dist_index_mjs--c7a61b.js.map
+0 −3 ...ons-vendors-node_modules_nextcloud_auth_dist_index_js-node_modules_nextcloud_vue_dist_Components_-304b96.js
+0 −1 ...vendors-node_modules_nextcloud_auth_dist_index_js-node_modules_nextcloud_vue_dist_Components_-304b96.js.map
+0 −3 js/notifications-vendors-node_modules_nextcloud_dialogs_dist_chunks_FilePicker-0bd54f66_mjs.js
+0 −1 js/notifications-vendors-node_modules_nextcloud_dialogs_dist_chunks_FilePicker-0bd54f66_mjs.js.map
+3 −0 js/notifications-vendors-node_modules_nextcloud_dialogs_dist_chunks_FilePicker-ClzJbciL_mjs.js
+57 −12 js/notifications-vendors-node_modules_nextcloud_dialogs_dist_chunks_FilePicker-ClzJbciL_mjs.js.LICENSE.txt
+1 −0 js/notifications-vendors-node_modules_nextcloud_dialogs_dist_chunks_FilePicker-ClzJbciL_mjs.js.map
+0 −3 ...ons-vendors-node_modules_nextcloud_moment_dist_index_js-node_modules_nextcloud_notify_push_dist_i-4dbea9.js
+0 −1 ...vendors-node_modules_nextcloud_moment_dist_index_js-node_modules_nextcloud_notify_push_dist_i-4dbea9.js.map
+3 −0 ...ons-vendors-node_modules_nextcloud_notify_push_dist_index_js-node_modules_howler_dist_howler_js-n-f0749c.js
+0 −0 ...node_modules_nextcloud_notify_push_dist_index_js-node_modules_howler_dist_howler_js-n-f0749c.js.LICENSE.txt
+1 −0 ...vendors-node_modules_nextcloud_notify_push_dist_index_js-node_modules_howler_dist_howler_js-n-f0749c.js.map
+3 −0 l10n/ast.js
+3 −0 l10n/ast.json
+3 −1 l10n/da.js
+3 −1 l10n/da.json
+19 −0 l10n/es_MX.js
+19 −0 l10n/es_MX.json
+3 −3 l10n/fa.js
+3 −3 l10n/fa.json
+1 −1 l10n/he.js
+1 −1 l10n/he.json
+1 −0 l10n/ko.js
+1 −0 l10n/ko.json
+3 −1 l10n/sk.js
+3 −1 l10n/sk.json
+1 −0 l10n/th.js
+1 −0 l10n/th.json
+3 −6 lib/AppInfo/Application.php
+2 −0 lib/Controller/APIController.php
+11 −7 lib/Controller/PushController.php
+3 −0 lib/Controller/SettingsController.php
+1 −9 lib/Handler.php
+49 −0 lib/Listener/AddMissingIndicesListener.php
+4 −3 lib/Listener/BeforeTemplateRenderedListener.php
+12 −5 lib/MailNotifications.php
+3 −2 lib/Migration/Version2010Date20210218082811.php
+1 −1 lib/Migration/Version2011Date20210930134607.php
+17 −7 lib/Push.php
+378 −0 openapi-administration.json
+1,556 −0 openapi-full.json
+466 −0 openapi-push.json
+12 −680 openapi.json
+823 −430 package-lock.json
+8 −8 package.json
+3 −3 psalm.xml
+1 −1 tests/Integration/base-query-count.txt
+229 −221 tests/Integration/composer.lock
+2 −2 tests/Integration/features/bootstrap/FeatureContext.php
+1 −1 tests/Unit/AppInfo/RoutesTest.php
+1 −13 tests/psalm-baseline.xml
+39 −22 vendor-bin/openapi-extractor/composer.lock
2 changes: 1 addition & 1 deletion external/nextcloud-server
Submodule nextcloud-server updated 3626 files
2 changes: 1 addition & 1 deletion external/nextcloud-spreed
Submodule nextcloud-spreed updated 735 files
12 changes: 6 additions & 6 deletions packages/app/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,10 @@ packages:
dependency: transitive
description:
name: camera_avfoundation
sha256: "9dbbb253aaf201a69c40cf95571f366ca936305d2de012684e21f6f1b1433d31"
sha256: "7d021e8cd30d9b71b8b92b4ad669e80af432d722d18d6aac338572754a786c15"
url: "https://pub.dev"
source: hosted
version: "0.9.15+4"
version: "0.9.16"
camera_platform_interface:
dependency: transitive
description:
Expand Down Expand Up @@ -527,10 +527,10 @@ packages:
dependency: transitive
description:
name: go_router
sha256: "771c8feb40ad0ef639973d7ecf1b43d55ffcedb2207fd43fab030f5639e40446"
sha256: "28ef8a8320ab3bf5752424e6bca6961ce25108afc344f3127b5155caf7a792c8"
url: "https://pub.dev"
source: hosted
version: "13.2.4"
version: "14.0.0"
hotreloader:
dependency: transitive
description:
Expand Down Expand Up @@ -671,10 +671,10 @@ packages:
dependency: transitive
description:
name: json_annotation
sha256: b10a7b2ff83d83c777edba3c6a0f97045ddadd56c944e1a23a3fdf43a1bf4467
sha256: "1ce844379ca14835a50d2f019a3099f419082cfdd231cd86a142af94dd5c6bb1"
url: "https://pub.dev"
source: hosted
version: "4.8.1"
version: "4.9.0"
leak_tracker:
dependency: transitive
description:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ TypeResult _resolveType(

case openapi.Schema(type: openapi.SchemaType.array):
final TypeResult subResult;
if (schema.maxLength == 0) {
if (schema.maxItems == 0) {
subResult = TypeResultBase('Never');
} else if (schema.items != null) {
subResult = resolveType(
Expand Down
62 changes: 40 additions & 22 deletions packages/dynamite/dynamite/lib/src/helpers/pattern_check.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,27 +7,45 @@ Iterable<Expression> buildPatternCheck(
String value,
String name,
) sync* {
if (schema.type == SchemaType.string) {
if (schema.pattern != null) {
yield refer('checkPattern', 'package:dynamite_runtime/utils.dart').call([
refer(value).asA(refer('String?')),
refer('RegExp').call([literalString(schema.pattern!, raw: true)]),
literalString(name),
]);
}
if (schema.minLength != null) {
yield refer('checkMinLength', 'package:dynamite_runtime/utils.dart').call([
refer(value).asA(refer('String?')),
literalNum(schema.minLength!),
literalString(name),
]);
}
if (schema.maxLength != null) {
yield refer('checkMaxLength', 'package:dynamite_runtime/utils.dart').call([
refer(value).asA(refer('String?')),
literalNum(schema.maxLength!),
literalString(name),
]);
}
switch (schema.type) {
case SchemaType.string:
if (schema.pattern != null) {
yield refer('checkPattern', 'package:dynamite_runtime/utils.dart').call([
refer(value).asA(refer('String?')),
refer('RegExp').call([literalString(schema.pattern!, raw: true)]),
literalString(name),
]);
}
if (schema.minLength != null) {
yield refer('checkMinLength', 'package:dynamite_runtime/utils.dart').call([
refer(value).asA(refer('String?')),
literalNum(schema.minLength!),
literalString(name),
]);
}
if (schema.maxLength != null) {
yield refer('checkMaxLength', 'package:dynamite_runtime/utils.dart').call([
refer(value).asA(refer('String?')),
literalNum(schema.maxLength!),
literalString(name),
]);
}
case SchemaType.array:
if (schema.minItems != null) {
yield refer('checkMinItems', 'package:dynamite_runtime/utils.dart').call([
refer(value).nullSafeProperty('length'),
literalNum(schema.minItems!),
literalString(name),
]);
}
if (schema.maxItems != null) {
yield refer('checkMaxItems', 'package:dynamite_runtime/utils.dart').call([
refer(value).nullSafeProperty('length'),
literalNum(schema.maxItems!),
literalString(name),
]);
}
default:
break;
}
}
4 changes: 4 additions & 0 deletions packages/dynamite/dynamite/lib/src/models/openapi/schema.dart
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@ abstract class Schema implements Built<Schema, SchemaBuilder> {

int? get maxLength;

int? get minItems;

int? get maxItems;

provokateurin marked this conversation as resolved.
Show resolved Hide resolved
bool get nullable;

@memoized
Expand Down
42 changes: 42 additions & 0 deletions packages/dynamite/dynamite/lib/src/models/openapi/schema.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
/// Pattern check test Version: 0.0.1.
library; // ignore_for_file: no_leading_underscores_for_library_prefixes

import 'package:built_collection/built_collection.dart';
import 'package:built_value/built_value.dart';
import 'package:built_value/serializer.dart';
import 'package:built_value/standard_json_plugin.dart' as _i4;
Expand All @@ -25,8 +26,14 @@ abstract interface class $TestObjectInterface {
String? get minLength;
@BuiltValueField(wireName: 'max-length')
String? get maxLength;
@BuiltValueField(wireName: 'multiple-checks')
String? get multipleChecks;
@BuiltValueField(wireName: 'string-multiple-checks')
String? get stringMultipleChecks;
@BuiltValueField(wireName: 'min-items')
BuiltList<int>? get minItems;
@BuiltValueField(wireName: 'max-items')
BuiltList<int>? get maxItems;
@BuiltValueField(wireName: 'array-multiple-checks')
BuiltList<int>? get arrayMultipleChecks;
@BuiltValueHook(initializeBuilder: true)
static void _defaults($TestObjectInterfaceBuilder b) {}
@BuiltValueHook(finalizeBuilder: true)
Expand All @@ -47,19 +54,39 @@ abstract interface class $TestObjectInterface {
'maxLength',
);
_i1.checkPattern(
b.multipleChecks,
b.stringMultipleChecks,
RegExp(r'^[0-9]*$'),
'multipleChecks',
'stringMultipleChecks',
);
_i1.checkMinLength(
b.multipleChecks,
b.stringMultipleChecks,
3,
'multipleChecks',
'stringMultipleChecks',
);
_i1.checkMaxLength(
b.multipleChecks,
b.stringMultipleChecks,
20,
'multipleChecks',
'stringMultipleChecks',
);
_i1.checkMinItems(
b.minItems.length,
3,
'minItems',
);
_i1.checkMaxItems(
b.maxItems.length,
20,
'maxItems',
);
_i1.checkMinItems(
b.arrayMultipleChecks.length,
3,
'arrayMultipleChecks',
);
_i1.checkMaxItems(
b.arrayMultipleChecks.length,
20,
'arrayMultipleChecks',
);
}
}
Expand Down Expand Up @@ -103,7 +130,8 @@ abstract class TestObject implements $TestObjectInterface, Built<TestObject, Tes
final Serializers $serializers = _$serializers;
final Serializers _$serializers = (Serializers().toBuilder()
..addBuilderFactory(const FullType(TestObject), TestObjectBuilder.new)
..add(TestObject.serializer))
..add(TestObject.serializer)
..addBuilderFactory(const FullType(BuiltList, [FullType(int)]), ListBuilder<int>.new))
.build();

/// Serializer for all values in this library.
Expand Down
Loading