@synopackageland/cli 0.6.1 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +846 -0
- package/README.md +81 -89
- package/dist/add.d.ts +4 -1
- package/dist/add.js +45 -17
- package/dist/build-spk/delegate-scope.d.ts +6 -0
- package/dist/build-spk/delegate-scope.js +34 -0
- package/dist/build-spk/dsm-arch.d.ts +7 -1
- package/dist/build-spk/dsm-arch.js +24 -28
- package/dist/build-spk/dsm-platforms.json +42 -0
- package/dist/build-spk/dsm-version.d.ts +11 -0
- package/dist/build-spk/dsm-version.js +17 -0
- package/dist/build-spk/gateway.js +8 -4
- package/dist/build-spk/generator.js +30 -5
- package/dist/build-spk/go-toolchain.d.ts +20 -0
- package/dist/build-spk/go-toolchain.js +44 -0
- package/dist/build-spk/notices.js +4 -1
- package/dist/build-spk/resource-worker.js +3 -0
- package/dist/build-spk/wizard-messages.d.ts +66 -0
- package/dist/build-spk/wizard-messages.js +75 -9
- package/dist/cli.js +28 -14
- package/dist/contract/schema-validate.js +8 -0
- package/dist/contract/validate.js +30 -0
- package/dist/deploy/deploy.d.ts +1 -1
- package/dist/deploy/deploy.js +8 -0
- package/dist/deploy/native-install-values.d.ts +17 -0
- package/dist/deploy/native-install-values.js +32 -0
- package/dist/deploy/plan.d.ts +6 -2
- package/dist/deploy/plan.js +58 -7
- package/dist/deploy/spk-version.js +1 -1
- package/dist/error-registry.js +54 -20
- package/dist/host/dsm-client.d.ts +8 -4
- package/dist/host/dsm-client.js +63 -21
- package/dist/host/dsm-http.js +24 -2
- package/dist/host/types.d.ts +3 -1
- package/dist/info.js +45 -10
- package/dist/init.d.ts +3 -0
- package/dist/init.js +50 -19
- package/dist/package-metadata.d.ts +21 -0
- package/dist/package-metadata.js +101 -0
- package/dist/portal/alias.d.ts +25 -0
- package/dist/portal/alias.js +48 -0
- package/dist/portal/package.d.ts +33 -0
- package/dist/portal/package.js +116 -0
- package/dist/runtime/delegate-contract.d.ts +79 -0
- package/dist/runtime/delegate-contract.js +27 -0
- package/dist/runtime/dsm-version.d.ts +6 -0
- package/dist/runtime/dsm-version.js +8 -0
- package/dist/runtime/executor-build.js +10 -6
- package/dist/runtime/executor-inspect.d.ts +3 -0
- package/dist/runtime/executor-inspect.js +11 -5
- package/dist/runtime/executor-policy.d.ts +12 -0
- package/dist/runtime/executor-policy.js +43 -3
- package/dist/runtime/executor-scope-task.d.ts +4 -0
- package/dist/runtime/executor-scope-task.js +21 -0
- package/dist/runtime/executor-tasks.d.ts +2 -1
- package/dist/runtime/executor-tasks.js +4 -4
- package/dist/skill.js +1 -0
- package/dist/standalone/api-permissions.d.ts +10 -0
- package/dist/standalone/api-permissions.js +19 -2
- package/dist/standalone/background.d.ts +16 -0
- package/dist/standalone/background.js +69 -2
- package/dist/standalone/binary.d.ts +1 -1
- package/dist/standalone/binary.js +22 -8
- package/dist/standalone/build.d.ts +1 -1
- package/dist/standalone/build.js +38 -8
- package/dist/standalone/daemon.d.ts +1 -0
- package/dist/standalone/daemon.js +10 -5
- package/dist/standalone/dsm-window.d.ts +3 -1
- package/dist/standalone/dsm-window.js +78 -49
- package/dist/standalone/inspect-spk.d.ts +8 -0
- package/dist/standalone/inspect-spk.js +110 -27
- package/dist/standalone/lifecycle.js +86 -8
- package/dist/standalone/manifest.d.ts +13 -0
- package/dist/standalone/manifest.js +57 -8
- package/dist/standalone/native-authorization-window.d.ts +1 -1
- package/dist/standalone/native-authorization-window.js +9 -1
- package/dist/standalone/native-layout.d.ts +3 -0
- package/dist/standalone/native-layout.js +37 -5
- package/dist/standalone/native-root-window.d.ts +4 -2
- package/dist/standalone/native-root-window.js +33 -18
- package/dist/standalone/portal-window.d.ts +21 -0
- package/dist/standalone/portal-window.js +155 -0
- package/dist/standalone/portal.d.ts +4 -0
- package/dist/standalone/portal.js +4 -0
- package/dist/standalone/resource.d.ts +5 -3
- package/dist/standalone/resource.js +6 -3
- package/dist/standalone/root-window.d.ts +4 -1
- package/dist/standalone/root-window.js +193 -36
- package/dist/standalone/spk.d.ts +1 -1
- package/dist/standalone/spk.js +25 -7
- package/dist/templates/_daemon/go.mod +1 -1
- package/dist/templates/_daemon/main.go +6 -3
- package/dist/templates/_daemon/main_test.go +82 -9
- package/dist/templates/_daemon/testdata/child.go +3 -0
- package/dist/templates/_executor/README.md +130 -16
- package/dist/templates/_executor/anchor.go +156 -0
- package/dist/templates/_executor/anchor_test.go +161 -0
- package/dist/templates/_executor/apppriv_review_test.go +1 -1
- package/dist/templates/_executor/cancel_contract_test.go +236 -0
- package/dist/templates/_executor/copy.go +64 -0
- package/dist/templates/_executor/copy_test.go +88 -0
- package/dist/templates/_executor/digest_review_test.go +2 -2
- package/dist/templates/_executor/dsm.go +63 -13
- package/dist/templates/_executor/dsm_test.go +95 -1
- package/dist/templates/_executor/executor.go +260 -49
- package/dist/templates/_executor/executor_test.go +36 -6
- package/dist/templates/_executor/go.mod +2 -0
- package/dist/templates/_executor/identity.go +27 -1
- package/dist/templates/_executor/identity_kernel_linux_test.go +60 -0
- package/dist/templates/_executor/identity_linux.go +82 -0
- package/dist/templates/_executor/identity_security_test.go +43 -0
- package/dist/templates/_executor/internal/lifecycle/lifecycle.go +5 -0
- package/dist/templates/_executor/internal/lifecycle/lifecycle_test.go +61 -3
- package/dist/templates/_executor/internal/taskscript/boot.sh +9 -9
- package/dist/templates/_executor/internal/taskscript/cmd/main.go +2 -2
- package/dist/templates/_executor/internal/taskscript/control.sh +15 -10
- package/dist/templates/_executor/internal/taskscript/tasks.go +5 -3
- package/dist/templates/_executor/lifecycle_test.go +11 -0
- package/dist/templates/_executor/link_linux.go +28 -0
- package/dist/templates/_executor/long_running_test.go +530 -0
- package/dist/templates/_executor/main.go +83 -25
- package/dist/templates/_executor/managed.go +3 -3
- package/dist/templates/_executor/managed_test.go +3 -3
- package/dist/templates/_executor/move_linux.go +490 -0
- package/dist/templates/_executor/move_linux_test.go +460 -0
- package/dist/templates/_executor/move_validation.go +46 -0
- package/dist/templates/_executor/move_validation_test.go +187 -0
- package/dist/templates/_executor/operations.go +926 -0
- package/dist/templates/_executor/path_test.go +18 -0
- package/dist/templates/_executor/pid.go +37 -0
- package/dist/templates/_executor/pid_test.go +113 -0
- package/dist/templates/_executor/platform_linux.go +24 -173
- package/dist/templates/_executor/platform_linux_test.go +9 -65
- package/dist/templates/_executor/platform_other.go +38 -4
- package/dist/templates/_executor/process.go +3 -0
- package/dist/templates/_executor/purge_log.go +18 -0
- package/dist/templates/_executor/records.go +242 -0
- package/dist/templates/_executor/scope_cancel_contract_test.go +91 -0
- package/dist/templates/_executor/scope_client.go +37 -0
- package/dist/templates/_executor/scope_contract.go +12 -0
- package/dist/templates/_executor/selected_scope.go +146 -0
- package/dist/templates/_executor/selected_scope_test.go +186 -0
- package/dist/templates/_executor/status_disabled_test.go +33 -0
- package/dist/templates/_executor/store.go +4 -3
- package/dist/templates/_executor/supervise.go +109 -0
- package/dist/templates/_executor/supervise_test.go +130 -0
- package/dist/templates/_executor/task_race_review_test.go +1 -1
- package/dist/templates/_executor/tasks.go +52 -15
- package/dist/templates/_executor/tasks_dsm71_test.go +114 -0
- package/dist/templates/_executor/tasks_review_test.go +1 -1
- package/dist/templates/_executor/tasks_test.go +62 -5
- package/dist/templates/_executor/upgrade_watch_test.go +13 -5
- package/dist/templates/_executor/watch.go +8 -0
- package/dist/templates/_executor/watch_test.go +23 -2
- package/dist/templates/_executor/write_review_linux_test.go +4 -12
- package/dist/templates/_gateway/go.mod +2 -0
- package/dist/templates/_shared/AGENTS.md +129 -0
- package/dist/templates/binary/dsm-package.yaml +24 -0
- package/dist/templates/binary/i18n/messages/de.json +4 -0
- package/dist/templates/binary/i18n/messages/en.json +4 -0
- package/dist/templates/binary/i18n/messages/es.json +4 -0
- package/dist/templates/binary/i18n/messages/fr.json +4 -0
- package/dist/templates/binary/i18n/messages/it.json +4 -0
- package/dist/templates/binary/i18n/messages/ja.json +4 -0
- package/dist/templates/binary/i18n/messages/ko.json +4 -0
- package/dist/templates/binary/i18n/messages/zh-CN.json +4 -0
- package/dist/templates/binary/i18n/messages/zh-TW.json +4 -0
- package/dist/templates/binary/ui/app.js +19 -4
- package/dist/templates/native-authorization/AuthorizationGate.vue +5 -3
- package/dist/templates/native-authorization/i18n/de.json +1 -0
- package/dist/templates/native-authorization/i18n/en.json +1 -0
- package/dist/templates/native-authorization/i18n/es.json +2 -1
- package/dist/templates/native-authorization/i18n/fr.json +1 -0
- package/dist/templates/native-authorization/i18n/it.json +11 -10
- package/dist/templates/native-authorization/i18n/ja.json +1 -0
- package/dist/templates/native-authorization/i18n/ko.json +10 -9
- package/dist/templates/native-authorization/i18n/zh-CN.json +6 -5
- package/dist/templates/native-authorization/i18n/zh-TW.json +6 -5
- package/dist/templates/native-go/README.md +43 -10
- package/dist/templates/native-go/backend/cmd/app/main.go +27 -7
- package/dist/templates/native-go/backend/go.mod +1 -1
- package/dist/templates/native-go/backend/internal/api/entry_test.go +47 -0
- package/dist/templates/native-go/backend/internal/api/permissions_test.go +3 -3
- package/dist/templates/native-go/backend/internal/api/registry.go +11 -0
- package/dist/templates/native-go/backend/internal/api/sdk-permissions.json +14 -1
- package/dist/templates/native-go/backend/internal/api/server.go +18 -5
- package/dist/templates/native-go/backend/internal/app/delegate_config.go +57 -0
- package/dist/templates/native-go/backend/internal/app/delegate_config_test.go +28 -0
- package/dist/templates/native-go/backend/internal/app/portal.go +30 -0
- package/dist/templates/native-go/backend/internal/app/portal_test.go +55 -0
- package/dist/templates/native-go/backend/internal/app/routes.go +8 -2
- package/dist/templates/native-go/backend/internal/background/runner.go +1 -1
- package/dist/templates/native-go/backend/internal/background/store.go +16 -14
- package/dist/templates/native-go/backend/internal/dsm/admin.go +8 -2
- package/dist/templates/native-go/backend/internal/dsm/admin_linux.go +43 -13
- package/dist/templates/native-go/backend/internal/dsm/admin_linux_test.go +56 -0
- package/dist/templates/native-go/backend/internal/dsm/admin_other.go +4 -1
- package/dist/templates/native-go/backend/internal/dsm/apppriv.go +30 -0
- package/dist/templates/native-go/backend/internal/dsm/bridge_file.go +75 -0
- package/dist/templates/native-go/backend/internal/dsm/bridge_file_test.go +57 -0
- package/dist/templates/native-go/backend/internal/dsm/entry.go +177 -0
- package/dist/templates/native-go/backend/internal/dsm/entry_test.go +315 -0
- package/dist/templates/native-go/backend/internal/dsm/native/admin-armv7.elf +0 -0
- package/dist/templates/native-go/backend/internal/dsm/native/apppriv-aarch64.elf +0 -0
- package/dist/templates/native-go/backend/internal/dsm/native/apppriv-armv7.elf +0 -0
- package/dist/templates/native-go/backend/internal/dsm/native/apppriv-x86_64.elf +0 -0
- package/dist/templates/native-go/backend/internal/dsm/native/apppriv_check.c +33 -0
- package/dist/templates/native-go/backend/internal/dsm/native/build.sh +13 -4
- package/dist/templates/native-go/backend/internal/dsm/native/provenance.json +9 -3
- package/dist/templates/native-go/backend/internal/filestation/check_permission.go +71 -0
- package/dist/templates/native-go/backend/internal/filestation/check_permission_test.go +77 -0
- package/dist/templates/native-go/backend/internal/filestation/client.go +39 -3
- package/dist/templates/native-go/backend/internal/filestation/download_dsm71_test.go +82 -0
- package/dist/templates/native-go/backend/internal/filestation/sdk_policy_test.go +39 -0
- package/dist/templates/native-go/backend/internal/filestation/service.go +1 -1
- package/dist/templates/native-go/backend/internal/identity/README.md +5 -1
- package/dist/templates/native-go/backend/internal/identity/dsm.go +24 -5
- package/dist/templates/native-go/backend/internal/identity/http.go +1 -1
- package/dist/templates/native-go/backend/internal/identity/identity_test.go +48 -1
- package/dist/templates/native-go/backend/internal/identity/service.go +1 -1
- package/dist/templates/native-go/backend/internal/portal/portal.go +138 -0
- package/dist/templates/native-go/backend/internal/portal/portal_test.go +89 -0
- package/dist/templates/native-go/dsm-package.yaml +20 -1
- package/dist/templates/native-go/i18n/glossary.json +2 -1
- package/dist/templates/native-go/i18n/messages/de.json +1 -0
- package/dist/templates/native-go/i18n/messages/en.json +1 -0
- package/dist/templates/native-go/i18n/messages/es.json +1 -0
- package/dist/templates/native-go/i18n/messages/fr.json +1 -0
- package/dist/templates/native-go/i18n/messages/it.json +1 -0
- package/dist/templates/native-go/i18n/messages/ja.json +1 -0
- package/dist/templates/native-go/i18n/messages/ko.json +1 -0
- package/dist/templates/native-go/i18n/messages/zh-CN.json +1 -0
- package/dist/templates/native-go/i18n/messages/zh-TW.json +1 -0
- package/dist/templates/native-go/ui/app.css +10 -0
- package/dist/templates/native-go/ui/app.js +11 -1
- package/dist/templates/native-go-delegate/DELEGATE.md +126 -5
- package/dist/templates/native-go-delegate/backend/cmd/background-worker/main.go +7 -0
- package/dist/templates/native-go-delegate/backend/internal/app/delegate.go +11 -1
- package/dist/templates/native-go-delegate/backend/internal/app/delegate_routes_test.go +14 -0
- package/dist/templates/native-go-delegate/backend/internal/background/delegated_moves.go +270 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/admission_recovery_test.go +410 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/cancel_contract_test.go +95 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/client.go +8 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/destination.go +110 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/destination_state.go +117 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/destination_state_test.go +60 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/destination_test.go +116 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/example.go +81 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/example_test.go +91 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/executor_contract_test.go +511 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/files.go +1 -1
- package/dist/templates/native-go-delegate/backend/internal/delegate/long_running_routes.go +92 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/long_running_routes_test.go +99 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/move.go +348 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/move_test.go +351 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/operations_list.go +65 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/operations_list_test.go +114 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/retry_test.go +1 -1
- package/dist/templates/native-go-delegate/backend/internal/delegate/service.go +58 -17
- package/dist/templates/native-go-delegate/backend/internal/delegate/staging.go +121 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/status_disabled_test.go +51 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/testdata/executor_contract.txt +112 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/transient_contract_test.go +137 -0
- package/dist/templates/native-go-delegate/backend/internal/filestation/files.go +1 -31
- package/dist/templates/native-go-delegate/frontend/src/CapabilityPanels.vue +30 -3
- package/dist/templates/native-go-delegate/frontend/src/delegate/BackgroundSavePanel.vue +113 -0
- package/dist/templates/native-go-delegate/frontend/src/delegate/copy.ts +5 -6
- package/dist/templates/native-go-delegate/frontend/test/background-save.test.ts +121 -0
- package/dist/templates/native-go-delegate/frontend/test/delegate.test.ts +15 -0
- package/dist/templates/native-go-delegate/frontend/test/scope-settings.test.ts +49 -0
- package/dist/templates/native-go-delegate/test.sh +1 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/de.json +2 -2
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/en.json +2 -2
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/es.json +12 -12
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/fr.json +4 -4
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/it.json +17 -17
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/ja.json +7 -7
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/ko.json +15 -15
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/zh-CN.json +3 -3
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/zh-TW.json +2 -2
- package/dist/templates/native-go-jobs/frontend/test/background.test.ts +25 -28
- package/dist/templates/native-go-root-ops/backend/internal/app/executor.go +30 -2
- package/dist/templates/native-go-root-ops/backend/internal/app/executor_test.go +64 -0
- package/dist/templates/native-go-vue/README.md +4 -0
- package/dist/templates/native-go-vue/frontend/package-lock.json +4 -4
- package/dist/templates/native-go-vue/frontend/package.json +1 -1
- package/dist/templates/native-go-vue/frontend/src/App.vue +18 -13
- package/dist/templates/native-go-vue/frontend/src/context.ts +31 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/ExecutorSettings.vue +54 -9
- package/dist/templates/native-go-vue/frontend/src/delegate/catalogs.ts +11 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/copy.test.ts +12 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/copy.ts +4 -4
- package/dist/templates/native-go-vue/frontend/src/delegate/executor-settings.test.ts +23 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/executor-setup.ts +8 -2
- package/dist/templates/native-go-vue/frontend/src/delegate/facade.test.ts +100 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/facade.ts +85 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/de.json +47 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/en.json +13 -2
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/es.json +47 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/fr.json +47 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/it.json +47 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/ja.json +47 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/ko.json +47 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/de.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/en.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/es.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/fr.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/it.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/ja.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/ko.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/zh-CN.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/save/zh-TW.json +42 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/zh-CN.json +47 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/zh-TW.json +16 -5
- package/dist/templates/native-go-vue/frontend/src/delegate/long-running.ts +57 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/save-copy.test.ts +12 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/save-copy.ts +24 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/scoped-picker.test.ts +12 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/scoped-picker.ts +21 -0
- package/dist/templates/native-go-vue/frontend/src/files/files.test.ts +7 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/de.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/en.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/es.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/fr.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/it.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/ja.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/ko.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/zh-CN.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n/zh-TW.json +20 -0
- package/dist/templates/native-go-vue/frontend/src/i18n.ts +13 -0
- package/dist/templates/native-go-vue/frontend/src/identity/LoginPage.vue +16 -14
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/de.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/en.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/es.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/fr.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/it.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/ja.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/ko.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/zh-CN.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n/zh-TW.json +27 -0
- package/dist/templates/native-go-vue/frontend/src/identity/i18n.ts +14 -0
- package/dist/templates/native-go-vue/frontend/src/identity/session.test.ts +4 -0
- package/dist/templates/native-go-vue/frontend/src/identity/session.ts +9 -8
- package/dist/templates/native-go-vue/frontend/src/nas/NasPicker.vue +31 -12
- package/dist/templates/native-go-vue/frontend/src/nas/destination.test.ts +48 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/de.json +1 -1
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/en.json +1 -1
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/es.json +10 -10
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/fr.json +1 -1
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/it.json +12 -12
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/ja.json +15 -15
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/ko.json +12 -12
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/zh-CN.json +1 -1
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/zh-TW.json +1 -1
- package/dist/templates/native-go-vue/frontend/src/portal/PortalSettings.vue +39 -0
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/fr.json +1 -1
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/ja.json +1 -1
- package/dist/templates/native-go-vue/frontend/test/apps.test.ts +14 -0
- package/dist/templates/native-go-vue/frontend/test/portal-settings.test.ts +71 -0
- package/dist/templates/native-go-vue/frontend/test/shell-i18n.test.ts +50 -0
- package/package.json +5 -1
- package/schema/package-metadata.schema.json +101 -0
- package/schema/synology-app.schema.json +112 -0
- package/skills/SKILL.md +106 -4
- package/skills/reference/create.md +101 -2
- package/skills/reference/deploy.md +2 -2
- package/skills/reference/files.md +113 -2
- package/skills/reference/identity.md +70 -1
- package/skills/reference/portal.md +17 -0
- package/skills/reference/ui-vue.md +12 -0
- package/templates/_daemon/go.mod +1 -1
- package/templates/_daemon/main.go +6 -3
- package/templates/_daemon/main_test.go +82 -9
- package/templates/_daemon/testdata/child.go +3 -0
- package/templates/_executor/README.md +130 -16
- package/templates/_executor/anchor.go +156 -0
- package/templates/_executor/anchor_test.go +161 -0
- package/templates/_executor/apppriv_review_test.go +1 -1
- package/templates/_executor/cancel_contract_test.go +236 -0
- package/templates/_executor/copy.go +64 -0
- package/templates/_executor/copy_test.go +88 -0
- package/templates/_executor/digest_review_test.go +2 -2
- package/templates/_executor/dsm.go +63 -13
- package/templates/_executor/dsm_test.go +95 -1
- package/templates/_executor/executor.go +260 -49
- package/templates/_executor/executor_test.go +36 -6
- package/templates/_executor/go.mod +2 -0
- package/templates/_executor/identity.go +27 -1
- package/templates/_executor/identity_kernel_linux_test.go +60 -0
- package/templates/_executor/identity_linux.go +82 -0
- package/templates/_executor/identity_security_test.go +43 -0
- package/templates/_executor/internal/lifecycle/lifecycle.go +5 -0
- package/templates/_executor/internal/lifecycle/lifecycle_test.go +61 -3
- package/templates/_executor/internal/taskscript/boot.sh +9 -9
- package/templates/_executor/internal/taskscript/cmd/main.go +2 -2
- package/templates/_executor/internal/taskscript/control.sh +15 -10
- package/templates/_executor/internal/taskscript/tasks.go +5 -3
- package/templates/_executor/lifecycle_test.go +11 -0
- package/templates/_executor/link_linux.go +28 -0
- package/templates/_executor/long_running_test.go +530 -0
- package/templates/_executor/main.go +83 -25
- package/templates/_executor/managed.go +3 -3
- package/templates/_executor/managed_test.go +3 -3
- package/templates/_executor/move_linux.go +490 -0
- package/templates/_executor/move_linux_test.go +460 -0
- package/templates/_executor/move_validation.go +46 -0
- package/templates/_executor/move_validation_test.go +187 -0
- package/templates/_executor/operations.go +926 -0
- package/templates/_executor/path_test.go +18 -0
- package/templates/_executor/pid.go +37 -0
- package/templates/_executor/pid_test.go +113 -0
- package/templates/_executor/platform_linux.go +24 -173
- package/templates/_executor/platform_linux_test.go +9 -65
- package/templates/_executor/platform_other.go +38 -4
- package/templates/_executor/process.go +3 -0
- package/templates/_executor/purge_log.go +18 -0
- package/templates/_executor/records.go +242 -0
- package/templates/_executor/scope_cancel_contract_test.go +91 -0
- package/templates/_executor/scope_client.go +37 -0
- package/templates/_executor/scope_contract.go +12 -0
- package/templates/_executor/selected_scope.go +146 -0
- package/templates/_executor/selected_scope_test.go +186 -0
- package/templates/_executor/status_disabled_test.go +33 -0
- package/templates/_executor/store.go +4 -3
- package/templates/_executor/supervise.go +109 -0
- package/templates/_executor/supervise_test.go +130 -0
- package/templates/_executor/task_race_review_test.go +1 -1
- package/templates/_executor/tasks.go +52 -15
- package/templates/_executor/tasks_dsm71_test.go +114 -0
- package/templates/_executor/tasks_review_test.go +1 -1
- package/templates/_executor/tasks_test.go +62 -5
- package/templates/_executor/upgrade_watch_test.go +13 -5
- package/templates/_executor/watch.go +8 -0
- package/templates/_executor/watch_test.go +23 -2
- package/templates/_executor/write_review_linux_test.go +4 -12
- package/templates/_gateway/go.mod +2 -0
- package/templates/_shared/AGENTS.md +129 -0
- package/templates/binary/dsm-package.yaml +24 -0
- package/templates/binary/i18n/messages/de.json +4 -0
- package/templates/binary/i18n/messages/en.json +4 -0
- package/templates/binary/i18n/messages/es.json +4 -0
- package/templates/binary/i18n/messages/fr.json +4 -0
- package/templates/binary/i18n/messages/it.json +4 -0
- package/templates/binary/i18n/messages/ja.json +4 -0
- package/templates/binary/i18n/messages/ko.json +4 -0
- package/templates/binary/i18n/messages/zh-CN.json +4 -0
- package/templates/binary/i18n/messages/zh-TW.json +4 -0
- package/templates/binary/ui/app.js +19 -4
- package/templates/native-authorization/AuthorizationGate.vue +5 -3
- package/templates/native-authorization/i18n/de.json +1 -0
- package/templates/native-authorization/i18n/en.json +1 -0
- package/templates/native-authorization/i18n/es.json +2 -1
- package/templates/native-authorization/i18n/fr.json +1 -0
- package/templates/native-authorization/i18n/it.json +11 -10
- package/templates/native-authorization/i18n/ja.json +1 -0
- package/templates/native-authorization/i18n/ko.json +10 -9
- package/templates/native-authorization/i18n/zh-CN.json +6 -5
- package/templates/native-authorization/i18n/zh-TW.json +6 -5
- package/templates/native-go/README.md +43 -10
- package/templates/native-go/backend/cmd/app/main.go +27 -7
- package/templates/native-go/backend/go.mod +1 -1
- package/templates/native-go/backend/internal/api/entry_test.go +47 -0
- package/templates/native-go/backend/internal/api/permissions_test.go +3 -3
- package/templates/native-go/backend/internal/api/registry.go +11 -0
- package/templates/native-go/backend/internal/api/sdk-permissions.json +14 -1
- package/templates/native-go/backend/internal/api/server.go +18 -5
- package/templates/native-go/backend/internal/app/delegate_config.go +57 -0
- package/templates/native-go/backend/internal/app/delegate_config_test.go +28 -0
- package/templates/native-go/backend/internal/app/portal.go +30 -0
- package/templates/native-go/backend/internal/app/portal_test.go +55 -0
- package/templates/native-go/backend/internal/app/routes.go +8 -2
- package/templates/native-go/backend/internal/background/runner.go +1 -1
- package/templates/native-go/backend/internal/background/store.go +16 -14
- package/templates/native-go/backend/internal/dsm/admin.go +8 -2
- package/templates/native-go/backend/internal/dsm/admin_linux.go +43 -13
- package/templates/native-go/backend/internal/dsm/admin_linux_test.go +56 -0
- package/templates/native-go/backend/internal/dsm/admin_other.go +4 -1
- package/templates/native-go/backend/internal/dsm/apppriv.go +30 -0
- package/templates/native-go/backend/internal/dsm/bridge_file.go +75 -0
- package/templates/native-go/backend/internal/dsm/bridge_file_test.go +57 -0
- package/templates/native-go/backend/internal/dsm/entry.go +177 -0
- package/templates/native-go/backend/internal/dsm/entry_test.go +315 -0
- package/templates/native-go/backend/internal/dsm/native/admin-armv7.elf +0 -0
- package/templates/native-go/backend/internal/dsm/native/apppriv-aarch64.elf +0 -0
- package/templates/native-go/backend/internal/dsm/native/apppriv-armv7.elf +0 -0
- package/templates/native-go/backend/internal/dsm/native/apppriv-x86_64.elf +0 -0
- package/templates/native-go/backend/internal/dsm/native/apppriv_check.c +33 -0
- package/templates/native-go/backend/internal/dsm/native/build.sh +13 -4
- package/templates/native-go/backend/internal/dsm/native/provenance.json +9 -3
- package/templates/native-go/backend/internal/filestation/check_permission.go +71 -0
- package/templates/native-go/backend/internal/filestation/check_permission_test.go +77 -0
- package/templates/native-go/backend/internal/filestation/client.go +39 -3
- package/templates/native-go/backend/internal/filestation/download_dsm71_test.go +82 -0
- package/templates/native-go/backend/internal/filestation/sdk_policy_test.go +39 -0
- package/templates/native-go/backend/internal/filestation/service.go +1 -1
- package/templates/native-go/backend/internal/identity/README.md +5 -1
- package/templates/native-go/backend/internal/identity/dsm.go +24 -5
- package/templates/native-go/backend/internal/identity/http.go +1 -1
- package/templates/native-go/backend/internal/identity/identity_test.go +48 -1
- package/templates/native-go/backend/internal/identity/service.go +1 -1
- package/templates/native-go/backend/internal/portal/portal.go +138 -0
- package/templates/native-go/backend/internal/portal/portal_test.go +89 -0
- package/templates/native-go/dsm-package.yaml +20 -1
- package/templates/native-go/i18n/glossary.json +2 -1
- package/templates/native-go/i18n/messages/de.json +1 -0
- package/templates/native-go/i18n/messages/en.json +1 -0
- package/templates/native-go/i18n/messages/es.json +1 -0
- package/templates/native-go/i18n/messages/fr.json +1 -0
- package/templates/native-go/i18n/messages/it.json +1 -0
- package/templates/native-go/i18n/messages/ja.json +1 -0
- package/templates/native-go/i18n/messages/ko.json +1 -0
- package/templates/native-go/i18n/messages/zh-CN.json +1 -0
- package/templates/native-go/i18n/messages/zh-TW.json +1 -0
- package/templates/native-go/ui/app.css +10 -0
- package/templates/native-go/ui/app.js +11 -1
- package/templates/native-go-delegate/DELEGATE.md +126 -5
- package/templates/native-go-delegate/backend/cmd/background-worker/main.go +7 -0
- package/templates/native-go-delegate/backend/internal/app/delegate.go +11 -1
- package/templates/native-go-delegate/backend/internal/app/delegate_routes_test.go +14 -0
- package/templates/native-go-delegate/backend/internal/background/delegated_moves.go +270 -0
- package/templates/native-go-delegate/backend/internal/delegate/admission_recovery_test.go +410 -0
- package/templates/native-go-delegate/backend/internal/delegate/cancel_contract_test.go +95 -0
- package/templates/native-go-delegate/backend/internal/delegate/client.go +8 -0
- package/templates/native-go-delegate/backend/internal/delegate/destination.go +110 -0
- package/templates/native-go-delegate/backend/internal/delegate/destination_state.go +117 -0
- package/templates/native-go-delegate/backend/internal/delegate/destination_state_test.go +60 -0
- package/templates/native-go-delegate/backend/internal/delegate/destination_test.go +116 -0
- package/templates/native-go-delegate/backend/internal/delegate/example.go +81 -0
- package/templates/native-go-delegate/backend/internal/delegate/example_test.go +91 -0
- package/templates/native-go-delegate/backend/internal/delegate/executor_contract_test.go +511 -0
- package/templates/native-go-delegate/backend/internal/delegate/files.go +1 -1
- package/templates/native-go-delegate/backend/internal/delegate/long_running_routes.go +92 -0
- package/templates/native-go-delegate/backend/internal/delegate/long_running_routes_test.go +99 -0
- package/templates/native-go-delegate/backend/internal/delegate/move.go +348 -0
- package/templates/native-go-delegate/backend/internal/delegate/move_test.go +351 -0
- package/templates/native-go-delegate/backend/internal/delegate/operations_list.go +65 -0
- package/templates/native-go-delegate/backend/internal/delegate/operations_list_test.go +114 -0
- package/templates/native-go-delegate/backend/internal/delegate/retry_test.go +1 -1
- package/templates/native-go-delegate/backend/internal/delegate/service.go +58 -17
- package/templates/native-go-delegate/backend/internal/delegate/staging.go +121 -0
- package/templates/native-go-delegate/backend/internal/delegate/status_disabled_test.go +51 -0
- package/templates/native-go-delegate/backend/internal/delegate/testdata/executor_contract.txt +112 -0
- package/templates/native-go-delegate/backend/internal/delegate/transient_contract_test.go +137 -0
- package/templates/native-go-delegate/backend/internal/filestation/files.go +1 -31
- package/templates/native-go-delegate/frontend/src/CapabilityPanels.vue +30 -3
- package/templates/native-go-delegate/frontend/src/delegate/BackgroundSavePanel.vue +113 -0
- package/templates/native-go-delegate/frontend/src/delegate/copy.ts +5 -6
- package/templates/native-go-delegate/frontend/test/background-save.test.ts +121 -0
- package/templates/native-go-delegate/frontend/test/delegate.test.ts +15 -0
- package/templates/native-go-delegate/frontend/test/scope-settings.test.ts +49 -0
- package/templates/native-go-delegate/test.sh +1 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/de.json +2 -2
- package/templates/native-go-jobs/frontend/src/background/i18n/en.json +2 -2
- package/templates/native-go-jobs/frontend/src/background/i18n/es.json +12 -12
- package/templates/native-go-jobs/frontend/src/background/i18n/fr.json +4 -4
- package/templates/native-go-jobs/frontend/src/background/i18n/it.json +17 -17
- package/templates/native-go-jobs/frontend/src/background/i18n/ja.json +7 -7
- package/templates/native-go-jobs/frontend/src/background/i18n/ko.json +15 -15
- package/templates/native-go-jobs/frontend/src/background/i18n/zh-CN.json +3 -3
- package/templates/native-go-jobs/frontend/src/background/i18n/zh-TW.json +2 -2
- package/templates/native-go-jobs/frontend/test/background.test.ts +25 -28
- package/templates/native-go-root-ops/backend/internal/app/executor.go +30 -2
- package/templates/native-go-root-ops/backend/internal/app/executor_test.go +64 -0
- package/templates/native-go-vue/README.md +4 -0
- package/templates/native-go-vue/frontend/package-lock.json +4 -4
- package/templates/native-go-vue/frontend/package.json +1 -1
- package/templates/native-go-vue/frontend/src/App.vue +18 -13
- package/templates/native-go-vue/frontend/src/context.ts +31 -0
- package/templates/native-go-vue/frontend/src/delegate/ExecutorSettings.vue +54 -9
- package/templates/native-go-vue/frontend/src/delegate/catalogs.ts +11 -0
- package/templates/native-go-vue/frontend/src/delegate/copy.test.ts +12 -0
- package/templates/native-go-vue/frontend/src/delegate/copy.ts +4 -4
- package/templates/native-go-vue/frontend/src/delegate/executor-settings.test.ts +23 -0
- package/templates/native-go-vue/frontend/src/delegate/executor-setup.ts +8 -2
- package/templates/native-go-vue/frontend/src/delegate/facade.test.ts +100 -0
- package/templates/native-go-vue/frontend/src/delegate/facade.ts +85 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/de.json +47 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/en.json +13 -2
- package/templates/native-go-vue/frontend/src/delegate/i18n/es.json +47 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/fr.json +47 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/it.json +47 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/ja.json +47 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/ko.json +47 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/de.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/en.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/es.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/fr.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/it.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/ja.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/ko.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/zh-CN.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/save/zh-TW.json +42 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/zh-CN.json +47 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/zh-TW.json +16 -5
- package/templates/native-go-vue/frontend/src/delegate/long-running.ts +57 -0
- package/templates/native-go-vue/frontend/src/delegate/save-copy.test.ts +12 -0
- package/templates/native-go-vue/frontend/src/delegate/save-copy.ts +24 -0
- package/templates/native-go-vue/frontend/src/delegate/scoped-picker.test.ts +12 -0
- package/templates/native-go-vue/frontend/src/delegate/scoped-picker.ts +21 -0
- package/templates/native-go-vue/frontend/src/files/files.test.ts +7 -0
- package/templates/native-go-vue/frontend/src/i18n/de.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n/en.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n/es.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n/fr.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n/it.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n/ja.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n/ko.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n/zh-CN.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n/zh-TW.json +20 -0
- package/templates/native-go-vue/frontend/src/i18n.ts +13 -0
- package/templates/native-go-vue/frontend/src/identity/LoginPage.vue +16 -14
- package/templates/native-go-vue/frontend/src/identity/i18n/de.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n/en.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n/es.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n/fr.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n/it.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n/ja.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n/ko.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n/zh-CN.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n/zh-TW.json +27 -0
- package/templates/native-go-vue/frontend/src/identity/i18n.ts +14 -0
- package/templates/native-go-vue/frontend/src/identity/session.test.ts +4 -0
- package/templates/native-go-vue/frontend/src/identity/session.ts +9 -8
- package/templates/native-go-vue/frontend/src/nas/NasPicker.vue +31 -12
- package/templates/native-go-vue/frontend/src/nas/destination.test.ts +48 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/de.json +1 -1
- package/templates/native-go-vue/frontend/src/nas/i18n/files/en.json +1 -1
- package/templates/native-go-vue/frontend/src/nas/i18n/files/es.json +10 -10
- package/templates/native-go-vue/frontend/src/nas/i18n/files/fr.json +1 -1
- package/templates/native-go-vue/frontend/src/nas/i18n/files/it.json +12 -12
- package/templates/native-go-vue/frontend/src/nas/i18n/files/ja.json +15 -15
- package/templates/native-go-vue/frontend/src/nas/i18n/files/ko.json +12 -12
- package/templates/native-go-vue/frontend/src/nas/i18n/files/zh-CN.json +1 -1
- package/templates/native-go-vue/frontend/src/nas/i18n/files/zh-TW.json +1 -1
- package/templates/native-go-vue/frontend/src/portal/PortalSettings.vue +39 -0
- package/templates/native-go-vue/frontend/src/shell/i18n/fr.json +1 -1
- package/templates/native-go-vue/frontend/src/shell/i18n/ja.json +1 -1
- package/templates/native-go-vue/frontend/test/apps.test.ts +14 -0
- package/templates/native-go-vue/frontend/test/portal-settings.test.ts +71 -0
- package/templates/native-go-vue/frontend/test/shell-i18n.test.ts +50 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"title": "Carpetas NAS — File Station",
|
|
3
|
-
"ownPermissions": "Las operaciones usan
|
|
3
|
+
"ownPermissions": "Las operaciones usan su sesión DSM y sus permisos actuales de File Station.",
|
|
4
4
|
"choose": "Elegir carpeta",
|
|
5
5
|
"confirm": "Confirmar selección",
|
|
6
6
|
"refresh": "Actualizar carpetas",
|
|
@@ -14,15 +14,15 @@
|
|
|
14
14
|
"cancel": "Cancelar",
|
|
15
15
|
"close": "Cerrar",
|
|
16
16
|
"loadMore": "Cargar más",
|
|
17
|
-
"errorSession": "La sesión DSM caducó.
|
|
17
|
+
"errorSession": "La sesión DSM caducó. Inicie sesión en DSM y actualice las carpetas.",
|
|
18
18
|
"errorDenied": "No tiene permiso para acceder a este archivo o carpeta. Elija otra carpeta.",
|
|
19
|
-
"errorNotFound": "El archivo o la carpeta ya no existe.
|
|
20
|
-
"errorConflict": "Ya existe un archivo o carpeta con ese nombre.
|
|
21
|
-
"errorUncertain": "La operación puede haber terminado.
|
|
22
|
-
"errorInvalid": "Carpeta, nombre o solicitud
|
|
23
|
-
"errorUnavailable": "File Station no está disponible o falta el adaptador de sesión.
|
|
24
|
-
"errorCanceled": "Solicitud cancelada.
|
|
25
|
-
"errorTimeout": "La solicitud agotó el tiempo.
|
|
19
|
+
"errorNotFound": "El archivo o la carpeta ya no existe. Actualice la lista.",
|
|
20
|
+
"errorConflict": "Ya existe un archivo o carpeta con ese nombre. Use otro nombre.",
|
|
21
|
+
"errorUncertain": "La operación puede haber terminado. Actualice las selecciones o el destino y compruebe el resultado antes de enviarla de nuevo.",
|
|
22
|
+
"errorInvalid": "Carpeta, nombre o solicitud no válidos. Revise los datos.",
|
|
23
|
+
"errorUnavailable": "File Station no está disponible o falta el adaptador de sesión. Actualice más tarde.",
|
|
24
|
+
"errorCanceled": "Solicitud cancelada. Actualice antes de continuar.",
|
|
25
|
+
"errorTimeout": "La solicitud agotó el tiempo. Actualice la lista antes de continuar.",
|
|
26
26
|
"metadata": "Metadatos",
|
|
27
27
|
"fileKind": "Archivo",
|
|
28
28
|
"directoryKind": "Carpeta",
|
|
@@ -37,5 +37,5 @@
|
|
|
37
37
|
"download": "Descargar",
|
|
38
38
|
"uploaded": "Archivo subido.",
|
|
39
39
|
"errorDSM": "Inicie sesión en DSM con este nombre de host para acceder a los archivos NAS. El inicio de sesión en la App por sí solo no permite usar File Station.",
|
|
40
|
-
"errorUploadSize": "Seleccione un archivo de hasta 16
|
|
40
|
+
"errorUploadSize": "Seleccione un archivo de hasta 16 GB."
|
|
41
41
|
}
|
|
@@ -37,5 +37,5 @@
|
|
|
37
37
|
"download": "Télécharger",
|
|
38
38
|
"uploaded": "Fichier téléversé.",
|
|
39
39
|
"errorDSM": "Connectez-vous à DSM sur ce nom d’hôte pour accéder aux fichiers NAS. La connexion à l’App seule ne permet pas d’utiliser File Station.",
|
|
40
|
-
"errorUploadSize": "Choisissez un fichier de 16
|
|
40
|
+
"errorUploadSize": "Choisissez un fichier de 16 GB maximum."
|
|
41
41
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"title": "Cartelle NAS — File Station",
|
|
3
|
-
"ownPermissions": "Le operazioni usano la
|
|
3
|
+
"ownPermissions": "Le operazioni usano la sessione DSM corrente e i relativi permessi File Station.",
|
|
4
4
|
"choose": "Scegli cartella",
|
|
5
5
|
"confirm": "Conferma selezione",
|
|
6
6
|
"refresh": "Aggiorna cartelle",
|
|
@@ -14,15 +14,15 @@
|
|
|
14
14
|
"cancel": "Annulla",
|
|
15
15
|
"close": "Chiudi",
|
|
16
16
|
"loadMore": "Carica altro",
|
|
17
|
-
"errorSession": "Sessione DSM scaduta.
|
|
18
|
-
"errorDenied": "
|
|
19
|
-
"errorNotFound": "Il file o la cartella non esiste più.
|
|
20
|
-
"errorConflict": "Esiste già un file o una cartella con questo nome.
|
|
21
|
-
"errorUncertain": "L’operazione potrebbe essere completata.
|
|
22
|
-
"errorInvalid": "Cartella, nome o richiesta non validi.
|
|
23
|
-
"errorUnavailable": "File Station non disponibile o adattatore di sessione mancante.
|
|
24
|
-
"errorCanceled": "Richiesta annullata.
|
|
25
|
-
"errorTimeout": "Tempo scaduto.
|
|
17
|
+
"errorSession": "Sessione DSM scaduta. Accedere di nuovo a DSM e aggiornare le cartelle.",
|
|
18
|
+
"errorDenied": "Nessun permesso di accesso a questo file o cartella. Scegliere un’altra cartella.",
|
|
19
|
+
"errorNotFound": "Il file o la cartella non esiste più. Aggiornare l’elenco.",
|
|
20
|
+
"errorConflict": "Esiste già un file o una cartella con questo nome. Scegliere un altro nome.",
|
|
21
|
+
"errorUncertain": "L’operazione potrebbe essere stata completata. Aggiornare selezioni o destinazione e controllare il risultato prima di inviarla di nuovo.",
|
|
22
|
+
"errorInvalid": "Cartella, nome o richiesta non validi. Controllare i dati.",
|
|
23
|
+
"errorUnavailable": "File Station non disponibile o adattatore di sessione mancante. Aggiornare più tardi.",
|
|
24
|
+
"errorCanceled": "Richiesta annullata. Aggiornare prima di continuare.",
|
|
25
|
+
"errorTimeout": "Tempo scaduto. Aggiornare l’elenco prima di continuare.",
|
|
26
26
|
"metadata": "Metadati",
|
|
27
27
|
"fileKind": "File",
|
|
28
28
|
"directoryKind": "Cartella",
|
|
@@ -36,6 +36,6 @@
|
|
|
36
36
|
"upload": "Carica",
|
|
37
37
|
"download": "Scarica",
|
|
38
38
|
"uploaded": "File caricato.",
|
|
39
|
-
"errorDSM": "
|
|
40
|
-
"errorUploadSize": "
|
|
39
|
+
"errorDSM": "Accedere a DSM con questo nome host per accedere ai file NAS. Il solo accesso all’App non consente di usare File Station.",
|
|
40
|
+
"errorUploadSize": "Selezionare un file fino a 16 GB."
|
|
41
41
|
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
|
-
"title": "NAS
|
|
2
|
+
"title": "NAS フォルダ — File Station",
|
|
3
3
|
"ownPermissions": "自分の DSM セッションと現在の File Station 権限で操作します。",
|
|
4
|
-
"choose": "
|
|
4
|
+
"choose": "フォルダを選択",
|
|
5
5
|
"confirm": "選択を確定",
|
|
6
|
-
"refresh": "
|
|
6
|
+
"refresh": "フォルダを最新の情報に更新",
|
|
7
7
|
"loading": "読み込み中…",
|
|
8
|
-
"emptyFolder": "
|
|
9
|
-
"roots": "
|
|
8
|
+
"emptyFolder": "空のフォルダです。",
|
|
9
|
+
"roots": "フォルダ",
|
|
10
10
|
"back": "戻る",
|
|
11
11
|
"select": "{name} を選択",
|
|
12
12
|
"open": "{name} を開く",
|
|
@@ -14,18 +14,18 @@
|
|
|
14
14
|
"cancel": "キャンセル",
|
|
15
15
|
"close": "閉じる",
|
|
16
16
|
"loadMore": "さらに読み込む",
|
|
17
|
-
"errorSession": "DSM セッションが期限切れです。DSM
|
|
17
|
+
"errorSession": "DSM セッションが期限切れです。DSM に再ログインし、フォルダを最新の情報に更新してください。",
|
|
18
18
|
"errorDenied": "このファイルまたはフォルダにアクセスする権限がありません。別のフォルダを選択してください。",
|
|
19
|
-
"errorNotFound": "
|
|
20
|
-
"errorConflict": "
|
|
21
|
-
"errorUncertain": "
|
|
22
|
-
"errorInvalid": "
|
|
23
|
-
"errorUnavailable": "File Station が利用できないか、このパッケージにセッション adapter
|
|
24
|
-
"errorCanceled": "
|
|
25
|
-
"errorTimeout": "
|
|
19
|
+
"errorNotFound": "ファイルまたはフォルダがありません。一覧を最新の情報に更新してください。",
|
|
20
|
+
"errorConflict": "同名のファイルまたはフォルダがあります。別の名前を指定してください。",
|
|
21
|
+
"errorUncertain": "操作が完了した可能性があります。再送信する前に選択または保存先を最新の情報に更新し、結果を確認してください。",
|
|
22
|
+
"errorInvalid": "フォルダ、ファイル名またはリクエストが無効です。入力を確認してください。",
|
|
23
|
+
"errorUnavailable": "File Station が利用できないか、このパッケージにセッション adapter がありません。後で最新の情報に更新してください。",
|
|
24
|
+
"errorCanceled": "リクエストをキャンセルしました。最新の情報に更新してから続けてください。",
|
|
25
|
+
"errorTimeout": "リクエストがタイムアウトしました。一覧を最新の情報に更新してください。",
|
|
26
26
|
"metadata": "情報",
|
|
27
27
|
"fileKind": "ファイル",
|
|
28
|
-
"directoryKind": "
|
|
28
|
+
"directoryKind": "フォルダ",
|
|
29
29
|
"nameColumn": "名前",
|
|
30
30
|
"kindColumn": "種類",
|
|
31
31
|
"sizeColumn": "バイト",
|
|
@@ -37,5 +37,5 @@
|
|
|
37
37
|
"download": "ダウンロード",
|
|
38
38
|
"uploaded": "ファイルをアップロードしました。",
|
|
39
39
|
"errorDSM": "NAS ファイルを利用するには同じホスト名で DSM にサインインしてください。App のログインだけでは File Station を利用できません。",
|
|
40
|
-
"errorUploadSize": "16
|
|
40
|
+
"errorUploadSize": "16 GB 以下のファイルを 1 つ選択してください。"
|
|
41
41
|
}
|
|
@@ -12,17 +12,17 @@
|
|
|
12
12
|
"open": "{name} 열기",
|
|
13
13
|
"selected": "선택됨: {name}",
|
|
14
14
|
"cancel": "취소",
|
|
15
|
-
"close": "
|
|
15
|
+
"close": "종료",
|
|
16
16
|
"loadMore": "더 불러오기",
|
|
17
|
-
"errorSession": "DSM 세션이 만료되었습니다. DSM에 다시 로그인한 후 폴더를 새로
|
|
18
|
-
"errorDenied": "이 파일 또는 폴더에 접근할 권한이 없습니다. 다른 폴더를
|
|
19
|
-
"errorNotFound": "파일 또는 폴더가 없습니다. 목록을 새로
|
|
20
|
-
"errorConflict": "같은 이름의 파일 또는 폴더가 있습니다. 다른 이름을
|
|
21
|
-
"errorUncertain": "작업이 완료되었을 수 있습니다. 다시 제출하기 전에 선택 또는 대상 폴더를 새로 고쳐 결과를
|
|
22
|
-
"errorInvalid": "폴더, 파일 이름 또는 요청이 잘못되었습니다. 입력을
|
|
23
|
-
"errorUnavailable": "File Station을 사용할 수 없거나 패키지에 세션 adapter가 없습니다. 나중에 새로
|
|
24
|
-
"errorCanceled": "요청이 취소되었습니다. 새로 고친 후
|
|
25
|
-
"errorTimeout": "요청 시간이 초과되었습니다. 목록을 새로
|
|
17
|
+
"errorSession": "DSM 세션이 만료되었습니다. DSM에 다시 로그인한 후 폴더를 새로 고치십시오.",
|
|
18
|
+
"errorDenied": "이 파일 또는 폴더에 접근할 권한이 없습니다. 다른 폴더를 선택하십시오.",
|
|
19
|
+
"errorNotFound": "파일 또는 폴더가 없습니다. 목록을 새로 고치십시오.",
|
|
20
|
+
"errorConflict": "같은 이름의 파일 또는 폴더가 있습니다. 다른 이름을 사용하십시오.",
|
|
21
|
+
"errorUncertain": "작업이 완료되었을 수 있습니다. 다시 제출하기 전에 선택 또는 대상 폴더를 새로 고쳐 결과를 확인하십시오.",
|
|
22
|
+
"errorInvalid": "폴더, 파일 이름 또는 요청이 잘못되었습니다. 입력을 확인하십시오.",
|
|
23
|
+
"errorUnavailable": "File Station을 사용할 수 없거나 패키지에 세션 adapter가 없습니다. 나중에 새로 고치십시오.",
|
|
24
|
+
"errorCanceled": "요청이 취소되었습니다. 새로 고친 후 계속하십시오.",
|
|
25
|
+
"errorTimeout": "요청 시간이 초과되었습니다. 목록을 새로 고치십시오.",
|
|
26
26
|
"metadata": "정보",
|
|
27
27
|
"fileKind": "파일",
|
|
28
28
|
"directoryKind": "폴더",
|
|
@@ -36,6 +36,6 @@
|
|
|
36
36
|
"upload": "업로드",
|
|
37
37
|
"download": "다운로드",
|
|
38
38
|
"uploaded": "파일을 업로드했습니다.",
|
|
39
|
-
"errorDSM": "NAS 파일에 접근하려면 같은 호스트 이름에서 DSM에
|
|
40
|
-
"errorUploadSize": "16
|
|
39
|
+
"errorDSM": "NAS 파일에 접근하려면 같은 호스트 이름에서 DSM에 로그인하십시오. App 로그인만으로는 File Station을 사용할 수 없습니다.",
|
|
40
|
+
"errorUploadSize": "16 GB 이하의 파일 하나를 선택하십시오."
|
|
41
41
|
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import {onBeforeUnmount,onMounted,ref} from 'vue'
|
|
3
|
+
import {Button,Callout,Form,FormActions,FormItem,Input,Link,SettingsSection} from '@synopackageland/ui'
|
|
4
|
+
import type {PortalAccess,PortalStatus} from '../context'
|
|
5
|
+
// SDK text in DSM's language comes with ctx.portal; DSM decides who may change the alias.
|
|
6
|
+
const props=defineProps<{portal:PortalAccess}>()
|
|
7
|
+
const m=props.portal.messages
|
|
8
|
+
const status=ref<PortalStatus>(),alias=ref(''),busy=ref(false),error=ref('')
|
|
9
|
+
let disposed=false
|
|
10
|
+
function show(next:PortalStatus){if(disposed)return;status.value=next;alias.value=next.alias||next.defaultAlias}
|
|
11
|
+
async function run(change:()=>Promise<PortalStatus>){
|
|
12
|
+
if(busy.value)return
|
|
13
|
+
busy.value=true;error.value=''
|
|
14
|
+
try{show(await change())}
|
|
15
|
+
catch(e){if(!disposed)error.value=m[(e as {code?:string})?.code||'']||m.portal_unavailable}
|
|
16
|
+
finally{if(!disposed)busy.value=false}
|
|
17
|
+
}
|
|
18
|
+
onMounted(()=>void props.portal.status().then(show))
|
|
19
|
+
onBeforeUnmount(()=>{disposed=true})
|
|
20
|
+
</script>
|
|
21
|
+
<template>
|
|
22
|
+
<SettingsSection v-if="status" :title="m.title" :collapsible="false" :aria-busy="busy">
|
|
23
|
+
<p v-if="status.state==='active'">{{ m.link }} <Link :href="status.url" external>{{ status.url }}</Link></p>
|
|
24
|
+
<template v-if="status.canManage">
|
|
25
|
+
<p v-if="status.state!=='active'">{{ m.inactive }}</p>
|
|
26
|
+
<Form @submit.prevent="run(()=>portal.apply(alias))">
|
|
27
|
+
<FormItem :label="m.alias" label-for="portal-alias"><Input id="portal-alias" v-model="alias" maxlength="64" autocomplete="off" :disabled="busy" /></FormItem>
|
|
28
|
+
<FormActions>
|
|
29
|
+
<Button type="submit" variant="primary" :disabled="busy">{{ m.apply }}</Button>
|
|
30
|
+
<Button v-if="status.state==='active'" variant="secondary" :disabled="busy" @click="run(()=>portal.disable())">{{ m.disable }}</Button>
|
|
31
|
+
</FormActions>
|
|
32
|
+
</Form>
|
|
33
|
+
<Button variant="secondary" @click="portal.openControlPanel()">{{ m.advanced }}</Button>
|
|
34
|
+
</template>
|
|
35
|
+
<Button v-else-if="status.controlPanel" variant="secondary" @click="portal.openControlPanel()">{{ m.controlPanel }}</Button>
|
|
36
|
+
<p v-else-if="status.state!=='active'">{{ m.askAdmin }}</p>
|
|
37
|
+
<Callout v-if="error" tone="danger"><span role="alert">{{ error }}</span></Callout>
|
|
38
|
+
</SettingsSection>
|
|
39
|
+
</template>
|
|
@@ -41,3 +41,17 @@ test('failed status loading offers a retry and releases the mounting class',asyn
|
|
|
41
41
|
f.app.unmount();expect(f.root.classList.contains('dsmapp-vue-root')).toBe(false)
|
|
42
42
|
}finally{f.close()}
|
|
43
43
|
})
|
|
44
|
+
test('a portal app shows the Application Portal section on the status page',async()=>{
|
|
45
|
+
const without=fixture('Plain')
|
|
46
|
+
const f=fixture('Portal')
|
|
47
|
+
try{
|
|
48
|
+
await settle();expect(without.root.textContent).not.toContain('Application Portal')
|
|
49
|
+
f.app.unmount()
|
|
50
|
+
const status={state:'active',alias:'portal',url:'https://nas.example/portal/',canManage:false,controlPanel:false,defaultAlias:'portal'} as const
|
|
51
|
+
f.ctx.portal={messages:{title:'Application Portal',link:'Direct link:'},status:vi.fn(async()=>status),apply:vi.fn(),disable:vi.fn(),openControlPanel:vi.fn(),mountPanel:vi.fn()}
|
|
52
|
+
const app=mount(f.root,f.ctx);await settle()
|
|
53
|
+
expect(f.root.textContent).toContain('Application Portal')
|
|
54
|
+
expect(f.root.querySelector('a[href="https://nas.example/portal/"]')).not.toBeNull()
|
|
55
|
+
app.unmount()
|
|
56
|
+
}finally{without.close();f.root.remove()}
|
|
57
|
+
})
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
// @vitest-environment jsdom
|
|
2
|
+
import {expect,test,vi} from 'vitest'
|
|
3
|
+
import {createApp,h,nextTick} from 'vue'
|
|
4
|
+
import {AppRoot} from '@synopackageland/ui'
|
|
5
|
+
import PortalSettings from '../src/portal/PortalSettings.vue'
|
|
6
|
+
import type {PortalAccess,PortalStatus} from '../src/context'
|
|
7
|
+
|
|
8
|
+
const messages={title:'Application Portal',link:'Direct link:',inactive:'Not active.',askAdmin:'Ask an administrator',alias:'Alias',apply:'Apply',disable:'Turn off',advanced:'Advanced',controlPanel:'Open Control Panel',portal_alias_in_use:'Alias in use',portal_unavailable:'DSM refused'}
|
|
9
|
+
const base:PortalStatus={state:'inactive',canManage:false,controlPanel:false,defaultAlias:'my-app'}
|
|
10
|
+
function access(status:PortalStatus,overrides:Partial<PortalAccess>={}):PortalAccess{
|
|
11
|
+
return {messages,status:vi.fn(async()=>status),apply:vi.fn(async()=>status),disable:vi.fn(async()=>status),openControlPanel:vi.fn(),mountPanel:vi.fn(),...overrides}
|
|
12
|
+
}
|
|
13
|
+
async function mount(portal:PortalAccess){
|
|
14
|
+
const root=document.createElement('div');document.body.append(root)
|
|
15
|
+
const app=createApp({render:()=>h(AppRoot,{},()=>h(PortalSettings,{portal}))})
|
|
16
|
+
app.mount(root);await nextTick();await nextTick();await new Promise(r=>setTimeout(r));await nextTick()
|
|
17
|
+
return {root,unmount(){app.unmount();root.remove()}}
|
|
18
|
+
}
|
|
19
|
+
const buttons=(root:HTMLElement)=>[...root.querySelectorAll('button')].map(b=>b.textContent?.trim())
|
|
20
|
+
|
|
21
|
+
test('an ordinary user sees the active link and nothing to change',async()=>{
|
|
22
|
+
const {root,unmount}=await mount(access({...base,state:'active',alias:'my-app',url:'https://nas.example/my-app/'}))
|
|
23
|
+
try{
|
|
24
|
+
expect(root.querySelector('a')?.getAttribute('href')).toBe('https://nas.example/my-app/')
|
|
25
|
+
expect(root.querySelector('input')).toBeNull();expect(root.querySelector('button')).toBeNull()
|
|
26
|
+
}finally{unmount()}
|
|
27
|
+
})
|
|
28
|
+
|
|
29
|
+
test('an ordinary user without an active alias is asked to contact an administrator',async()=>{
|
|
30
|
+
const {root,unmount}=await mount(access({...base,state:'unavailable'}))
|
|
31
|
+
try{
|
|
32
|
+
expect(root.textContent).toContain('Ask an administrator')
|
|
33
|
+
expect(root.querySelector('a,input,button')).toBeNull()
|
|
34
|
+
}finally{unmount()}
|
|
35
|
+
})
|
|
36
|
+
|
|
37
|
+
test('an administrator applies the prefilled alias and sees DSM refusals as portal text',async()=>{
|
|
38
|
+
const apply=vi.fn(async()=>Promise.reject({code:'portal_alias_in_use'}))
|
|
39
|
+
const portal=access({...base,canManage:true},{apply})
|
|
40
|
+
const {root,unmount}=await mount(portal)
|
|
41
|
+
try{
|
|
42
|
+
const input=root.querySelector('input')!
|
|
43
|
+
expect(input.value).toBe('my-app')
|
|
44
|
+
root.querySelector('form')!.dispatchEvent(new Event('submit',{cancelable:true}))
|
|
45
|
+
await new Promise(r=>setTimeout(r));await nextTick()
|
|
46
|
+
expect(apply).toHaveBeenCalledWith('my-app')
|
|
47
|
+
expect(root.querySelector('[role="alert"]')?.textContent).toContain('Alias in use')
|
|
48
|
+
;[...root.querySelectorAll('button')].find(b=>b.textContent?.includes('Advanced'))!.click()
|
|
49
|
+
expect(portal.openControlPanel).toHaveBeenCalled()
|
|
50
|
+
}finally{unmount()}
|
|
51
|
+
})
|
|
52
|
+
|
|
53
|
+
test('an administrator turns an active alias off',async()=>{
|
|
54
|
+
const portal=access({...base,state:'active',alias:'my-app',url:'https://nas.example/my-app/',canManage:true})
|
|
55
|
+
const {root,unmount}=await mount(portal)
|
|
56
|
+
try{
|
|
57
|
+
expect(root.querySelector('a')?.getAttribute('href')).toBe('https://nas.example/my-app/')
|
|
58
|
+
;[...root.querySelectorAll('button')].find(b=>b.textContent?.includes('Turn off'))!.click()
|
|
59
|
+
await nextTick()
|
|
60
|
+
expect(portal.disable).toHaveBeenCalled()
|
|
61
|
+
}finally{unmount()}
|
|
62
|
+
})
|
|
63
|
+
|
|
64
|
+
test('an administrator without DSM portal support gets only the Control Panel shortcut',async()=>{
|
|
65
|
+
const portal=access({...base,state:'unavailable',controlPanel:true})
|
|
66
|
+
const {root,unmount}=await mount(portal)
|
|
67
|
+
try{
|
|
68
|
+
expect(root.querySelector('input')).toBeNull()
|
|
69
|
+
expect(buttons(root)).toEqual(['Open Control Panel'])
|
|
70
|
+
}finally{unmount()}
|
|
71
|
+
})
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
// @vitest-environment jsdom
|
|
2
|
+
// @vitest-environment-options {"url":"https://nas.test"}
|
|
3
|
+
import {expect,test,vi} from 'vitest'
|
|
4
|
+
import {nextTick} from 'vue'
|
|
5
|
+
import {mount} from '../src/main'
|
|
6
|
+
import type {Context} from '../src/context'
|
|
7
|
+
import {appCopy} from '../src/i18n'
|
|
8
|
+
import {identityCopy} from '../src/identity/i18n'
|
|
9
|
+
async function settle(){for(let i=0;i<20;i++){await Promise.resolve();await nextTick()}}
|
|
10
|
+
const buttons=(root:HTMLElement)=>[...root.querySelectorAll('button')].map(b=>b.textContent?.trim())
|
|
11
|
+
function start(locale:string,call:(method:string)=>Promise<unknown>){
|
|
12
|
+
const ctx={locale,call:vi.fn(call),reopen(){return ()=>{}}} as unknown as Context
|
|
13
|
+
const root=document.createElement('div');document.body.append(root)
|
|
14
|
+
const app=mount(root,ctx)
|
|
15
|
+
return {root,close(){app.unmount();root.remove()}}
|
|
16
|
+
}
|
|
17
|
+
test('the status page and its errors follow the DSM language',async()=>{
|
|
18
|
+
const copy=appCopy('ger')
|
|
19
|
+
const {root,close}=start('de',async method=>{
|
|
20
|
+
if(method==='app.status')return {package:'Pkg',version:'1',user:'admin',admin:true}
|
|
21
|
+
if(method==='greeting.get')throw {code:'admin_required'}
|
|
22
|
+
throw {code:'unknown_method'}
|
|
23
|
+
})
|
|
24
|
+
try{
|
|
25
|
+
await settle()
|
|
26
|
+
expect(buttons(root)).toContain(copy.refresh)
|
|
27
|
+
expect(root.textContent).toContain(copy.statusTitle)
|
|
28
|
+
expect(root.textContent).toContain(copy.greeting)
|
|
29
|
+
expect(root.textContent).toContain(copy.errors.admin_required)
|
|
30
|
+
expect(root.querySelector('[aria-label]')?.getAttribute('aria-label')).not.toBe('Package settings')
|
|
31
|
+
}finally{close()}
|
|
32
|
+
})
|
|
33
|
+
test('unknown failures name the code in the DSM language',()=>{
|
|
34
|
+
expect(appCopy('ja').errors.request_failed).toContain('{code}')
|
|
35
|
+
})
|
|
36
|
+
test('the sign-in page and its session notices follow the DSM language',async()=>{
|
|
37
|
+
const copy=identityCopy('jpn')
|
|
38
|
+
const {root,close}=start('ja',async method=>{
|
|
39
|
+
if(method==='identity.status')return {enabled:true}
|
|
40
|
+
if(method==='identity.session')return {user:'alice',uid:'1',expiresAt:new Date(Date.now()-1000).toISOString()}
|
|
41
|
+
throw {code:'session_required'}
|
|
42
|
+
})
|
|
43
|
+
try{
|
|
44
|
+
await settle()
|
|
45
|
+
expect(root.textContent).toContain(copy.title)
|
|
46
|
+
expect(buttons(root)).toEqual(expect.arrayContaining([copy.signIn,copy.continueDSM]))
|
|
47
|
+
expect(root.querySelector('[role="status"]')?.textContent).toBe(copy.notices.expired)
|
|
48
|
+
expect(root.textContent).not.toMatch(/Sign in|Account|Password|session/)
|
|
49
|
+
}finally{close()}
|
|
50
|
+
})
|
package/package.json
CHANGED
|
@@ -1,13 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@synopackageland/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.1",
|
|
4
4
|
"description": "Syno Package Land Developer Kit CLI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
7
|
"synopkgland": "./dist/bin.js"
|
|
8
8
|
},
|
|
9
|
+
"engines": {
|
|
10
|
+
"node": ">=22.12"
|
|
11
|
+
},
|
|
9
12
|
"files": [
|
|
10
13
|
"dist",
|
|
14
|
+
"CHANGELOG.md",
|
|
11
15
|
"templates",
|
|
12
16
|
"schema",
|
|
13
17
|
"skills"
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"type": "object",
|
|
4
|
+
"additionalProperties": false,
|
|
5
|
+
"properties": {
|
|
6
|
+
"changelog": {
|
|
7
|
+
"oneOf": [
|
|
8
|
+
{
|
|
9
|
+
"type": "string",
|
|
10
|
+
"maxLength": 16000
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
"type": "object",
|
|
14
|
+
"maxProperties": 32,
|
|
15
|
+
"additionalProperties": {
|
|
16
|
+
"type": "string",
|
|
17
|
+
"maxLength": 16000
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
"contact_email": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"maxLength": 16000,
|
|
25
|
+
"pattern": "^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"
|
|
26
|
+
},
|
|
27
|
+
"support_email": {
|
|
28
|
+
"type": "string",
|
|
29
|
+
"maxLength": 16000,
|
|
30
|
+
"pattern": "^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"
|
|
31
|
+
},
|
|
32
|
+
"homepage": {
|
|
33
|
+
"type": "string",
|
|
34
|
+
"maxLength": 16000,
|
|
35
|
+
"pattern": "^https?://"
|
|
36
|
+
},
|
|
37
|
+
"source_url": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"maxLength": 16000,
|
|
40
|
+
"pattern": "^https?://"
|
|
41
|
+
},
|
|
42
|
+
"issues_url": {
|
|
43
|
+
"type": "string",
|
|
44
|
+
"maxLength": 16000,
|
|
45
|
+
"pattern": "^https?://"
|
|
46
|
+
},
|
|
47
|
+
"license": {
|
|
48
|
+
"type": "string",
|
|
49
|
+
"maxLength": 16000
|
|
50
|
+
},
|
|
51
|
+
"maintainer_url": {
|
|
52
|
+
"type": "string",
|
|
53
|
+
"maxLength": 16000,
|
|
54
|
+
"pattern": "^https?://"
|
|
55
|
+
},
|
|
56
|
+
"distributor": {
|
|
57
|
+
"type": "string",
|
|
58
|
+
"maxLength": 16000
|
|
59
|
+
},
|
|
60
|
+
"distributor_url": {
|
|
61
|
+
"type": "string",
|
|
62
|
+
"maxLength": 16000,
|
|
63
|
+
"pattern": "^https?://"
|
|
64
|
+
},
|
|
65
|
+
"support_url": {
|
|
66
|
+
"type": "string",
|
|
67
|
+
"maxLength": 16000,
|
|
68
|
+
"pattern": "^(https?://|mailto:)"
|
|
69
|
+
},
|
|
70
|
+
"helpurl": {
|
|
71
|
+
"type": "string",
|
|
72
|
+
"maxLength": 16000,
|
|
73
|
+
"pattern": "^https?://"
|
|
74
|
+
},
|
|
75
|
+
"long_description": {
|
|
76
|
+
"oneOf": [
|
|
77
|
+
{
|
|
78
|
+
"type": "string",
|
|
79
|
+
"maxLength": 16000
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"type": "object",
|
|
83
|
+
"maxProperties": 32,
|
|
84
|
+
"additionalProperties": {
|
|
85
|
+
"type": "string",
|
|
86
|
+
"maxLength": 16000
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
]
|
|
90
|
+
},
|
|
91
|
+
"screenshots": {
|
|
92
|
+
"type": "array",
|
|
93
|
+
"maxItems": 12,
|
|
94
|
+
"items": {
|
|
95
|
+
"type": "string",
|
|
96
|
+
"pattern": "^https?://",
|
|
97
|
+
"maxLength": 2048
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
@@ -118,6 +118,18 @@
|
|
|
118
118
|
"pattern": "^(?:[A-Za-z0-9._-]{1,64}|[A-Za-z0-9._-]{1,64}\\\\[A-Za-z0-9._-](?:[A-Za-z0-9._ -]{0,126}[A-Za-z0-9._-])?|[A-Za-z0-9._-](?:[A-Za-z0-9._ -]{0,126}[A-Za-z0-9._-])?@[A-Za-z0-9._-]{1,64})$(?![\\s\\S])"
|
|
119
119
|
},
|
|
120
120
|
"description": "DSM group names allowed in; only with access: dsm-groups."
|
|
121
|
+
},
|
|
122
|
+
"portal": {
|
|
123
|
+
"type": "object",
|
|
124
|
+
"properties": {
|
|
125
|
+
"alias": {
|
|
126
|
+
"type": "string",
|
|
127
|
+
"pattern": "^[a-z0-9](?:[a-z0-9-]{0,62}[a-z0-9])?$",
|
|
128
|
+
"description": "Default DSM Application Portal alias (https://<nas>/<alias>/). Omit to use the package name. An administrator still applies it."
|
|
129
|
+
}
|
|
130
|
+
},
|
|
131
|
+
"additionalProperties": false,
|
|
132
|
+
"description": "Register the App in DSM Control Panel > Login Portal > Applications. Needs launch: dsm-window behind the DSM gateway (access other than public) and os_min_ver 7.3.2-86009 or later. Registration alone exposes nothing."
|
|
121
133
|
}
|
|
122
134
|
},
|
|
123
135
|
"additionalProperties": true
|
|
@@ -149,6 +161,106 @@
|
|
|
149
161
|
"type": "boolean"
|
|
150
162
|
}
|
|
151
163
|
}
|
|
164
|
+
},
|
|
165
|
+
"metadata": {
|
|
166
|
+
"type": "object",
|
|
167
|
+
"additionalProperties": false,
|
|
168
|
+
"properties": {
|
|
169
|
+
"changelog": {
|
|
170
|
+
"oneOf": [
|
|
171
|
+
{
|
|
172
|
+
"type": "string",
|
|
173
|
+
"maxLength": 16000
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
"type": "object",
|
|
177
|
+
"maxProperties": 32,
|
|
178
|
+
"additionalProperties": {
|
|
179
|
+
"type": "string",
|
|
180
|
+
"maxLength": 16000
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
]
|
|
184
|
+
},
|
|
185
|
+
"contact_email": {
|
|
186
|
+
"type": "string",
|
|
187
|
+
"maxLength": 16000,
|
|
188
|
+
"pattern": "^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"
|
|
189
|
+
},
|
|
190
|
+
"support_email": {
|
|
191
|
+
"type": "string",
|
|
192
|
+
"maxLength": 16000,
|
|
193
|
+
"pattern": "^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"
|
|
194
|
+
},
|
|
195
|
+
"homepage": {
|
|
196
|
+
"type": "string",
|
|
197
|
+
"maxLength": 16000,
|
|
198
|
+
"pattern": "^https?://"
|
|
199
|
+
},
|
|
200
|
+
"source_url": {
|
|
201
|
+
"type": "string",
|
|
202
|
+
"maxLength": 16000,
|
|
203
|
+
"pattern": "^https?://"
|
|
204
|
+
},
|
|
205
|
+
"issues_url": {
|
|
206
|
+
"type": "string",
|
|
207
|
+
"maxLength": 16000,
|
|
208
|
+
"pattern": "^https?://"
|
|
209
|
+
},
|
|
210
|
+
"license": {
|
|
211
|
+
"type": "string",
|
|
212
|
+
"maxLength": 16000
|
|
213
|
+
},
|
|
214
|
+
"maintainer_url": {
|
|
215
|
+
"type": "string",
|
|
216
|
+
"maxLength": 16000,
|
|
217
|
+
"pattern": "^https?://"
|
|
218
|
+
},
|
|
219
|
+
"distributor": {
|
|
220
|
+
"type": "string",
|
|
221
|
+
"maxLength": 16000
|
|
222
|
+
},
|
|
223
|
+
"distributor_url": {
|
|
224
|
+
"type": "string",
|
|
225
|
+
"maxLength": 16000,
|
|
226
|
+
"pattern": "^https?://"
|
|
227
|
+
},
|
|
228
|
+
"support_url": {
|
|
229
|
+
"type": "string",
|
|
230
|
+
"maxLength": 16000,
|
|
231
|
+
"pattern": "^(https?://|mailto:)"
|
|
232
|
+
},
|
|
233
|
+
"helpurl": {
|
|
234
|
+
"type": "string",
|
|
235
|
+
"maxLength": 16000,
|
|
236
|
+
"pattern": "^https?://"
|
|
237
|
+
},
|
|
238
|
+
"long_description": {
|
|
239
|
+
"oneOf": [
|
|
240
|
+
{
|
|
241
|
+
"type": "string",
|
|
242
|
+
"maxLength": 16000
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
"type": "object",
|
|
246
|
+
"maxProperties": 32,
|
|
247
|
+
"additionalProperties": {
|
|
248
|
+
"type": "string",
|
|
249
|
+
"maxLength": 16000
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
]
|
|
253
|
+
},
|
|
254
|
+
"screenshots": {
|
|
255
|
+
"type": "array",
|
|
256
|
+
"maxItems": 12,
|
|
257
|
+
"items": {
|
|
258
|
+
"type": "string",
|
|
259
|
+
"pattern": "^https?://",
|
|
260
|
+
"maxLength": 2048
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
}
|
|
152
264
|
}
|
|
153
265
|
},
|
|
154
266
|
"additionalProperties": true
|