diff --git a/apps/settings/src/components/Encryption.vue b/apps/settings/src/components/Encryption.vue
deleted file mode 100644
index 8ef0807948856..0000000000000
--- a/apps/settings/src/components/Encryption.vue
+++ /dev/null
@@ -1,188 +0,0 @@
-
-
-
- {{ t('settings', 'Please read carefully before activating server-side encryption:') }}
- {{ t('settings', 'This is the final warning: Do you really want to enable encryption?') }}
-
- {{ t('settings', 'No encryption module loaded, please enable an encryption module in the app menu.') }}
-
+ {{ textExistingFilesNotEncrypted }}
+ {{ t('settings', 'To encrypt all existing files run this OCC command:') }}
+
+ {{ t('settings', 'Disabling server side encryption is only possible using OCC, please refer to the documentation.') }}
+
+ {{ t('settings', 'Please read carefully before activating server-side encryption:') }}
+
-
-
- {{ t('settings', 'Select default encryption module:') }}
-
-
-
+
+ occ encryption:encrypt-all
+ {{ t('settings', 'Select default encryption module:') }}
+
+
+
+
+ {{ t('settings', 'This is the final warning: Do you really want to enable encryption?') }} +
+ + + + diff --git a/apps/settings/src/components/Encryption/sharedTexts.ts b/apps/settings/src/components/Encryption/sharedTexts.ts new file mode 100644 index 0000000000000..94d23be07f231 --- /dev/null +++ b/apps/settings/src/components/Encryption/sharedTexts.ts @@ -0,0 +1,7 @@ +/*! + * SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors + * SPDX-License-Identifier: AGPL-3.0-or-later + */ +import { t } from '@nextcloud/l10n' + +export const textExistingFilesNotEncrypted = t('settings', 'For performance reasons, when you enable encryption on a Nextcloud server only new and changed files are encrypted.') diff --git a/apps/settings/src/main-admin-security.js b/apps/settings/src/main-admin-security.js index 2893c7fa0485b..5248ff3b5fe20 100644 --- a/apps/settings/src/main-admin-security.js +++ b/apps/settings/src/main-admin-security.js @@ -7,7 +7,7 @@ import { loadState } from '@nextcloud/initial-state' import Vue from 'vue' import AdminTwoFactor from './components/AdminTwoFactor.vue' -import Encryption from './components/Encryption.vue' +import EncryptionSettings from './components/Encryption/EncryptionSettings.vue' import store from './store/admin-security.js' // eslint-disable-next-line camelcase @@ -28,5 +28,5 @@ new View({ store, }).$mount('#two-factor-auth-settings') -const EncryptionView = Vue.extend(Encryption) +const EncryptionView = Vue.extend(EncryptionSettings) new EncryptionView().$mount('#vue-admin-encryption') diff --git a/dist/core-common.js b/dist/core-common.js index ef37c090f9117..6943f0890f3a8 100644 --- a/dist/core-common.js +++ b/dist/core-common.js @@ -1,2 +1,2 @@ -(self.webpackChunknextcloud=self.webpackChunknextcloud||[]).push([[4208],{30352:(e,t,n)=>{"use strict";n.d(t,{ZL:()=>l});var a=n(85471);function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}var i={selector:"vue-portal-target-".concat(((e=21)=>{let t="",n=e;for(;n--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[64*Math.random()|0];return t})())},o="undefined"!=typeof window&&void 0!==("undefined"==typeof document?"undefined":r(document)),s=a.Ay.extend({abstract:!0,name:"PortalOutlet",props:["nodes","tag"],data:function(e){return{updatedNodes:e.nodes}},render:function(e){var t=this.updatedNodes&&this.updatedNodes();return t?1!==t.length||t[0].text?e(this.tag||"DIV",t):t:e()},destroyed:function(){var e=this.$el;e&&e.parentNode.removeChild(e)}}),l=a.Ay.extend({name:"VueSimplePortal",props:{disabled:{type:Boolean},prepend:{type:Boolean},selector:{type:String,default:function(){return"#".concat(i.selector)}},tag:{type:String,default:"DIV"}},render:function(e){if(this.disabled){var t=this.$scopedSlots&&this.$scopedSlots.default();return t?t.length<2&&!t[0].text?t:e(this.tag,t):e()}return e()},created:function(){this.getTargetEl()||this.insertTargetEl()},updated:function(){var e=this;this.$nextTick((function(){e.disabled||e.slotFn===e.$scopedSlots.default||(e.container.updatedNodes=e.$scopedSlots.default),e.slotFn=e.$scopedSlots.default}))},beforeDestroy:function(){this.unmount()},watch:{disabled:{immediate:!0,handler:function(e){e?this.unmount():this.$nextTick(this.mount)}}},methods:{getTargetEl:function(){if(o)return document.querySelector(this.selector)},insertTargetEl:function(){if(o){var e=document.querySelector("body"),t=document.createElement(this.tag);t.id=this.selector.substring(1),e.appendChild(t)}},mount:function(){if(o){var e=this.getTargetEl(),t=document.createElement("DIV");this.prepend&&e.firstChild?e.insertBefore(t,e.firstChild):e.appendChild(t),this.container=new s({el:t,parent:this,propsData:{tag:this.tag,nodes:this.$scopedSlots.default}})}},unmount:function(){this.container&&(this.container.$destroy(),delete this.container)}}});"undefined"!=typeof window&&window.Vue&&window.Vue===a.Ay&&a.Ay.use((function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};e.component(n.name||"portal",l),n.defaultSelector&&(t=n.defaultSelector,i.selector=t)}))},42660:(e,t,n)=>{"use strict";var a=n(49574),r=Object.prototype.hasOwnProperty,i={align:"text-align",valign:"vertical-align",height:"height",width:"width"};function o(e){var t;if("tr"===e.tagName||"td"===e.tagName||"th"===e.tagName)for(t in i)r.call(i,t)&&void 0!==e.properties[t]&&(s(e,i[t],e.properties[t]),delete e.properties[t])}function s(e,t,n){var a=(e.properties.style||"").trim();a&&!/;\s*/.test(a)&&(a+=";"),a&&(a+=" ");var r=a+t+": "+n+";";e.properties.style=r}e.exports=function(e){return a(e,"element",o),e}},20856:e=>{"use strict";function t(e){if("string"==typeof e)return function(e){return function(t){return Boolean(t&&t.type===e)}}(e);if(null==e)return r;if("object"==typeof e)return("length"in e?a:n)(e);if("function"==typeof e)return e;throw new Error("Expected function, string, or object as test")}function n(e){return function(t){var n;for(n in e)if(t[n]!==e[n])return!1;return!0}}function a(e){var n=function(e){for(var n=[],a=e.length,r=-1;++r{"use strict";e.exports=s;var a=n(20856),r=!0,i="skip",o=!1;function s(e,t,n,r){var s;"function"==typeof t&&"function"!=typeof n&&(r=n,n=t,t=null),s=a(t),function e(a,u,d){var c,h=[];return(t&&!s(a,u,d[d.length-1]||null)||(h=l(n(a,d)))[0]!==o)&&a.children&&h[0]!==i?(c=l(function(t,n){for(var a,i=r?-1:1,s=(r?t.length:-1)+i;s>-1&&s-1)r&&r.push(i);else if(u=ge(i),o=De(c.appendChild(i),"script"),u&&Se(o),n)for(d=0;i=o[d++];)Te.test(i.type||"")&&n.push(i);return c}var Le=/^([^.]*)(?:\.(.+)|)/;function Ne(){return!0}function Oe(){return!1}function je(e,t,n,a,r,i){var o,s;if("object"==typeof t){for(s in"string"!=typeof n&&(a=a||n,n=void 0),t)je(e,s,n,a,t[s],i);return e}if(null==a&&null==r?(r=n,a=n=void 0):null==r&&("string"==typeof n?(r=a,a=void 0):(r=a,a=n,n=void 0)),!1===r)r=Oe;else if(!r)return e;return 1===i&&(o=r,r=function(e){return E().off(e),o.apply(this,arguments)},r.guid=o.guid||(o.guid=E.guid++)),e.each((function(){E.event.add(this,t,r,a,n)}))}function Ye(e,t,n){n?(se.set(e,t,!1),E.event.add(e,t,{namespace:!1,handler:function(e){var n,a=se.get(this,t);if(1&e.isTrigger&&this[t]){if(a)(E.event.special[t]||{}).delegateType&&e.stopPropagation();else if(a=s.call(arguments),se.set(this,t,a),this[t](),n=se.get(this,t),se.set(this,t,!1),a!==n)return e.stopImmediatePropagation(),e.preventDefault(),n}else a&&(se.set(this,t,E.event.trigger(a[0],a.slice(1),this)),e.stopPropagation(),e.isImmediatePropagationStopped=Ne)}})):void 0===se.get(e,t)&&E.event.add(e,t,Ne)}E.event={global:{},add:function(e,t,n,a,r){var i,o,s,l,u,d,c,h,f,p,m,g=se.get(e);if(ie(e))for(n.handler&&(n=(i=n).handler,r=i.selector),r&&E.find.matchesSelector(me,r),n.guid||(n.guid=E.guid++),(l=g.events)||(l=g.events=Object.create(null)),(o=g.handle)||(o=g.handle=function(t){return void 0!==E&&E.event.triggered!==t.type?E.event.dispatch.apply(e,arguments):void 0}),u=(t=(t||"").match(W)||[""]).length;u--;)f=m=(s=Le.exec(t[u])||[])[1],p=(s[2]||"").split(".").sort(),f&&(c=E.event.special[f]||{},f=(r?c.delegateType:c.bindType)||f,c=E.event.special[f]||{},d=E.extend({type:f,origType:m,data:a,handler:n,guid:n.guid,selector:r,needsContext:r&&E.expr.match.needsContext.test(r),namespace:p.join(".")},i),(h=l[f])||((h=l[f]=[]).delegateCount=0,c.setup&&!1!==c.setup.call(e,a,p,o)||e.addEventListener&&e.addEventListener(f,o)),c.add&&(c.add.call(e,d),d.handler.guid||(d.handler.guid=n.guid)),r?h.splice(h.delegateCount++,0,d):h.push(d),E.event.global[f]=!0)},remove:function(e,t,n,a,r){var i,o,s,l,u,d,c,h,f,p,m,g=se.hasData(e)&&se.get(e);if(g&&(l=g.events)){for(u=(t=(t||"").match(W)||[""]).length;u--;)if(f=m=(s=Le.exec(t[u])||[])[1],p=(s[2]||"").split(".").sort(),f){for(c=E.event.special[f]||{},h=l[f=(a?c.delegateType:c.bindType)||f]||[],s=s[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),o=i=h.length;i--;)d=h[i],!r&&m!==d.origType||n&&n.guid!==d.guid||s&&!s.test(d.namespace)||a&&a!==d.selector&&("**"!==a||!d.selector)||(h.splice(i,1),d.selector&&h.delegateCount--,c.remove&&c.remove.call(e,d));o&&!h.length&&(c.teardown&&!1!==c.teardown.call(e,p,g.handle)||E.removeEvent(e,f,g.handle),delete l[f])}else for(f in l)E.event.remove(e,f+t[u],n,a,!0);E.isEmptyObject(l)&&se.remove(e,"handle events")}},dispatch:function(e){var t,n,a,r,i,o,s=new Array(arguments.length),l=E.event.fix(e),u=(se.get(this,"events")||Object.create(null))[l.type]||[],d=E.event.special[l.type]||{};for(s[0]=l,t=1;t