diff --git a/emhttp/plugins/dynamix.gui.search/gui_search.page b/emhttp/plugins/dynamix.gui.search/gui_search.page index 52bc3c265..ae6eed9f4 100644 --- a/emhttp/plugins/dynamix.gui.search/gui_search.page +++ b/emhttp/plugins/dynamix.gui.search/gui_search.page @@ -18,19 +18,6 @@ $guiSearchBoxSpan = "= 0: return 'Edge'; // Edge - case agent.indexOf('edg/') >= 0: return 'Edge'; // Edge Chromium Based - case agent.indexOf('opr') >= 0 && !!window.opr: return 'Opera'; - case agent.indexOf('chrome') >= 0 && !!window.chrome: return 'Chrome'; - case agent.indexOf('trident') >= 0: return 'MS IE'; - case agent.indexOf('firefox') >= 0: return 'Mozilla Firefox'; - case agent.indexOf('safari') >= 0: return 'Safari'; - default: return 'other'; - } -})(window.navigator.userAgent.toLowerCase()); - $(function(){ isSidebarTheme()):?> $('.nav-item.gui_search').hover(function(){gui_search();},function(e){closeSearchBox(e);}); @@ -56,10 +43,6 @@ function setupGUIsearch() { } }); - if (browserName != 'Chrome' && browserName != 'Edge') { - var hashTag = (window.location.hash||'').substr(1).replace('%20',' ').replace('%2d','-'); - if (hashTag.length) $('body').mark(hashTag,{'accuracy': {'value': 'exactly','limiters': ['.',':','?']},'separateWordSearch': false}); - } } function gui_search() { @@ -97,19 +80,21 @@ function closeSearchBox(e) { function guiSearch() { var searchInfo = $('#guiSearchBox').val().split('**'); - var separator = (browserName == 'Chrome' || browserName == 'Edge') ? '#:~:text=' : '#'; + var separator = ('fragmentDirective' in document) ? '#:~:text=' : '#'; var scrollText = (typeof searchInfo[1] != 'undefined') ? separator+searchInfo[1].replace(' ','%20').replace('-','%2d') : ''; var newPage = "/Settings/Tools".replace(searchInfo[0]+'/',''); closeSearchBox(event); if (newPage == 'Dashboard/Settings/Tools') newPage = 'Settings'; - location.replace('/'+newPage+'/'+searchInfo[0]+scrollText); -} - -if (browserName != 'Chrome' && browserName != 'Edge') { - var script = document.createElement('script'); - script.type = 'text/javascript'; - script.src = ''; - document.getElementsByTagName('head')[0].appendChild(script); + + /** + * Prevents Community Apps from crashing + * Hook script provided by CA - https://github.com/unraid/community.applications/blob/master/source/community.applications/usr/local/emhttp/plugins/community.applications/javascript/helpers.js + */ + if ( typeof guiSearchOnUnload === "function" ) { + guiSearchOnUnload(); + } + + location.assign('/'+newPage+'/'+searchInfo[0]+scrollText); } diff --git a/emhttp/plugins/dynamix.gui.search/javascript/jquery.mark.js b/emhttp/plugins/dynamix.gui.search/javascript/jquery.mark.js deleted file mode 100644 index 1cf9d52db..000000000 --- a/emhttp/plugins/dynamix.gui.search/javascript/jquery.mark.js +++ /dev/null @@ -1,10 +0,0 @@ -/*!*************************************************** -* mark.js v9.0.0 -* https://markjs.io/ -* Copyright (c) 2014–2018, Julian Kühnel -* Released under the MIT license https://git.io/vwTVl -*****************************************************/ -!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],t):e.Mark=t(e.jQuery)}(this,function(e){"use strict";function t(e){return(t="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})(e)}function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){for(var n=0;n1&&void 0!==arguments[1])||arguments[1],o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:5e3;n(this,e),this.ctx=t,this.iframes=r,this.exclude=o,this.iframesTimeout=i}return o(e,[{key:"getContexts",value:function(){var e=[];return(void 0!==this.ctx&&this.ctx?NodeList.prototype.isPrototypeOf(this.ctx)?Array.prototype.slice.call(this.ctx):Array.isArray(this.ctx)?this.ctx:"string"==typeof this.ctx?Array.prototype.slice.call(document.querySelectorAll(this.ctx)):[this.ctx]:[]).forEach(function(t){var n=e.filter(function(e){return e.contains(t)}).length>0;-1!==e.indexOf(t)||n||e.push(t)}),e}},{key:"getIframeContents",value:function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){};try{var o=e.contentWindow;if(n=o.document,!o||!n)throw new Error("iframe inaccessible")}catch(e){r()}n&&t(n)}},{key:"isIframeBlank",value:function(e){var t="about:blank",n=e.getAttribute("src").trim();return e.contentWindow.location.href===t&&n!==t&&n}},{key:"observeIframeLoad",value:function(e,t,n){var r=this,o=!1,i=null,a=function a(){if(!o){o=!0,clearTimeout(i);try{r.isIframeBlank(e)||(e.removeEventListener("load",a),r.getIframeContents(e,t,n))}catch(e){n()}}};e.addEventListener("load",a),i=setTimeout(a,this.iframesTimeout)}},{key:"onIframeReady",value:function(e,t,n){try{"complete"===e.contentWindow.document.readyState?this.isIframeBlank(e)?this.observeIframeLoad(e,t,n):this.getIframeContents(e,t,n):this.observeIframeLoad(e,t,n)}catch(e){n()}}},{key:"waitForIframes",value:function(e,t){var n=this,r=0;this.forEachIframe(e,function(){return!0},function(e){r++,n.waitForIframes(e.querySelector("html"),function(){--r||t()})},function(e){e||t()})}},{key:"forEachIframe",value:function(t,n,r){var o=this,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:function(){},a=t.querySelectorAll("iframe"),s=a.length,c=0;a=Array.prototype.slice.call(a);var u=function(){--s<=0&&i(c)};s||u(),a.forEach(function(t){e.matches(t,o.exclude)?u():o.onIframeReady(t,function(e){n(t)&&(c++,r(e)),u()},u)})}},{key:"createIterator",value:function(e,t,n){return document.createNodeIterator(e,t,n,!1)}},{key:"createInstanceOnIframe",value:function(t){return new e(t.querySelector("html"),this.iframes)}},{key:"compareNodeIframe",value:function(e,t,n){if(e.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_PRECEDING){if(null===t)return!0;if(t.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_FOLLOWING)return!0}return!1}},{key:"getIteratorNode",value:function(e){var t=e.previousNode();return{prevNode:t,node:null===t?e.nextNode():e.nextNode()&&e.nextNode()}}},{key:"checkIframeFilter",value:function(e,t,n,r){var o=!1,i=!1;return r.forEach(function(e,t){e.val===n&&(o=t,i=e.handled)}),this.compareNodeIframe(e,t,n)?(!1!==o||i?!1===o||i||(r[o].handled=!0):r.push({val:n,handled:!0}),!0):(!1===o&&r.push({val:n,handled:!1}),!1)}},{key:"handleOpenIframes",value:function(e,t,n,r){var o=this;e.forEach(function(e){e.handled||o.getIframeContents(e.val,function(e){o.createInstanceOnIframe(e).forEachNode(t,n,r)})})}},{key:"iterateThroughNodes",value:function(e,t,n,r,o){for(var i,a,s,c=this,u=this.createIterator(t,e,r),l=[],h=[];s=void 0,s=c.getIteratorNode(u),a=s.prevNode,i=s.node;)this.iframes&&this.forEachIframe(t,function(e){return c.checkIframeFilter(i,a,e,l)},function(t){c.createInstanceOnIframe(t).forEachNode(e,function(e){return h.push(e)},r)}),h.push(i);h.forEach(function(e){n(e)}),this.iframes&&this.handleOpenIframes(l,e,n,r),o()}},{key:"forEachNode",value:function(e,t,n){var r=this,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:function(){},i=this.getContexts(),a=i.length;a||o(),i.forEach(function(i){var s=function(){r.iterateThroughNodes(e,i,t,n,function(){--a<=0&&o()})};r.iframes?r.waitForIframes(i,s):s()})}}],[{key:"matches",value:function(e,t){var n="string"==typeof t?[t]:t,r=e.matches||e.matchesSelector||e.msMatchesSelector||e.mozMatchesSelector||e.oMatchesSelector||e.webkitMatchesSelector;if(r){var o=!1;return n.every(function(t){return!r.call(e,t)||(o=!0,!1)}),o}return!1}}]),e}(),s= -function(){function e(t){n(this,e),this.opt=i({},{diacritics:!0,synonyms:{},accuracy:"partially",caseSensitive:!1,ignoreJoiners:!1,ignorePunctuation:[],wildcards:"disabled"},t)}return o(e,[{key:"create",value:function(e){return"disabled"!==this.opt.wildcards&&(e=this.setupWildcardsRegExp(e)),e=this.escapeStr(e),Object.keys(this.opt.synonyms).length&&(e=this.createSynonymsRegExp(e)),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.setupIgnoreJoinersRegExp(e)),this.opt.diacritics&&(e=this.createDiacriticsRegExp(e)),e=this.createMergedBlanksRegExp(e),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.createJoinersRegExp(e)),"disabled"!==this.opt.wildcards&&(e=this.createWildcardsRegExp(e)),e=this.createAccuracyRegExp(e),new RegExp(e,"gm".concat(this.opt.caseSensitive?"":"i"))}},{key:"sortByLength",value:function(e){return e.sort(function(e,t){return e.length===t.length?e>t?1:-1:t.length-e.length})}},{key:"escapeStr",value:function(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}},{key:"createSynonymsRegExp",value:function(e){var t=this,n=this.opt.synonyms,r=this.opt.caseSensitive?"":"i",o=this.opt.ignoreJoiners||this.opt.ignorePunctuation.length?"\0":"";for(var i in n)if(n.hasOwnProperty(i)){var a=Array.isArray(n[i])?n[i]:[n[i]];a.unshift(i),(a=this.sortByLength(a).map(function(e){return"disabled"!==t.opt.wildcards&&(e=t.setupWildcardsRegExp(e)),e=t.escapeStr(e)}).filter(function(e){return""!==e})).length>1&&(e=e.replace(new RegExp("(".concat(a.map(function(e){return t.escapeStr(e)}).join("|"),")"),"gm".concat(r)),o+"(".concat(a.map(function(e){return t.processSynonyms(e)}).join("|"),")")+o))}return e}},{key:"processSynonyms",value:function(e){return(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.setupIgnoreJoinersRegExp(e)),e}},{key:"setupWildcardsRegExp",value:function(e){return(e=e.replace(/(?:\\)*\?/g,function(e){return"\\"===e.charAt(0)?"?":""})).replace(/(?:\\)*\*/g,function(e){return"\\"===e.charAt(0)?"*":""})}},{key:"createWildcardsRegExp",value:function(e){var t="withSpaces"===this.opt.wildcards;return e.replace(/\u0001/g,t?"[\\S\\s]?":"\\S?").replace(/\u0002/g,t?"[\\S\\s]*?":"\\S*")}},{key:"setupIgnoreJoinersRegExp",value:function(e){return e.replace(/[^(|)\\]/g,function(e,t,n){var r=n.charAt(t+1);return/[(|)\\]/.test(r)||""===r?e:e+"\0"})}},{key:"createJoinersRegExp",value:function(e){var t=[],n=this.opt.ignorePunctuation;return Array.isArray(n)&&n.length&&t.push(this.escapeStr(n.join(""))),this.opt.ignoreJoiners&&t.push("\\u00ad\\u200b\\u200c\\u200d"),t.length?e.split(/\u0000+/).join("[".concat(t.join(""),"]*")):e}},{key:"createDiacriticsRegExp",value:function(e){var t=this.opt.caseSensitive?"":"i",n=this.opt.caseSensitive?["aàáảãạăằắẳẵặâầấẩẫậäåāą","AÀÁẢÃẠĂẰẮẲẴẶÂẦẤẨẪẬÄÅĀĄ","cçćč","CÇĆČ","dđď","DĐĎ","eèéẻẽẹêềếểễệëěēę","EÈÉẺẼẸÊỀẾỂỄỆËĚĒĘ","iìíỉĩịîïī","IÌÍỈĨỊÎÏĪ","lł","LŁ","nñňń","NÑŇŃ","oòóỏõọôồốổỗộơởỡớờợöøō","OÒÓỎÕỌÔỒỐỔỖỘƠỞỠỚỜỢÖØŌ","rř","RŘ","sšśșş","SŠŚȘŞ","tťțţ","TŤȚŢ","uùúủũụưừứửữựûüůū","UÙÚỦŨỤƯỪỨỬỮỰÛÜŮŪ","yýỳỷỹỵÿ","YÝỲỶỸỴŸ","zžżź","ZŽŻŹ"]:["aàáảãạăằắẳẵặâầấẩẫậäåāąAÀÁẢÃẠĂẰẮẲẴẶÂẦẤẨẪẬÄÅĀĄ","cçćčCÇĆČ","dđďDĐĎ","eèéẻẽẹêềếểễệëěēęEÈÉẺẼẸÊỀẾỂỄỆËĚĒĘ","iìíỉĩịîïīIÌÍỈĨỊÎÏĪ","lłLŁ","nñňńNÑŇŃ","oòóỏõọôồốổỗộơởỡớờợöøōOÒÓỎÕỌÔỒỐỔỖỘƠỞỠỚỜỢÖØŌ","rřRŘ","sšśșşSŠŚȘŞ","tťțţTŤȚŢ","uùúủũụưừứửữựûüůūUÙÚỦŨỤƯỪỨỬỮỰÛÜŮŪ","yýỳỷỹỵÿYÝỲỶỸỴŸ","zžżźZŽŻŹ"],r=[];return e.split("").forEach(function(o){n.every(function(n){if(-1!==n.indexOf(o)){if(r.indexOf(n)>-1)return!1;e=e.replace(new RegExp("[".concat(n,"]"),"gm".concat(t)),"[".concat(n,"]")),r.push(n)}return!0})}),e}},{key:"createMergedBlanksRegExp",value:function(e){return e.replace(/[\s]+/gim,"[\\s]+")}},{key:"createAccuracyRegExp",value:function(e){var t=this,n=this.opt.accuracy,r="string"==typeof n?n:n.value,o="string"==typeof n?[]:n.limiters,i="";switch(o.forEach(function(e){i+="|".concat(t.escapeStr(e))}),r){case"partially":default:return"()(".concat(e,")");case"complementary":return i="\\s"+(i||this.escapeStr("!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~¡¿")),"()([^".concat(i,"]*").concat(e,"[^").concat(i,"]*)");case"exactly":return"(^|\\s".concat(i,")(").concat(e,")(?=$|\\s").concat(i,")")}}}]),e}(),c= -function(){function e(t){n(this,e),this.ctx=t,this.ie=!1;var r=window.navigator.userAgent;(r.indexOf("MSIE")>-1||r.indexOf("Trident")>-1)&&(this.ie=!0)}return o(e,[{key:"log",value:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"debug",r=this.opt.log;this.opt.debug&&"object"===t(r)&&"function"==typeof r[n]&&r[n]("mark.js: ".concat(e))}},{key:"getSeparatedKeywords",value:function(e){var t=this,n=[];return e.forEach(function(e){t.opt.separateWordSearch?e.split(" ").forEach(function(e){e.trim()&&-1===n.indexOf(e)&&n.push(e)}):e.trim()&&-1===n.indexOf(e)&&n.push(e)}),{keywords:n.sort(function(e,t){return t.length-e.length}),length:n.length}}},{key:"isNumeric",value:function(e){return Number(parseFloat(e))==e}},{key:"checkRanges",value:function(e){var t=this;if(!Array.isArray(e)||"[object Object]"!==Object.prototype.toString.call(e[0]))return this.log("markRanges() will only accept an array of objects"),this.opt.noMatch(e),[];var n=[],r=0;return e.sort(function(e,t){return e.start-t.start}).forEach(function(e){var o=t.callNoMatchOnInvalidRanges(e,r),i=o.start,a=o.end;o.valid&&(e.start=i,e.length=a-i,n.push(e),r=a)}),n}},{key:"callNoMatchOnInvalidRanges",value:function(e,t){var n,r,o=!1;return e&&void 0!==e.start?(r=(n=parseInt(e.start,10))+parseInt(e.length,10),this.isNumeric(e.start)&&this.isNumeric(e.length)&&r-t>0&&r-n>0?o=!0:(this.log("Ignoring invalid or overlapping range: "+"".concat(JSON.stringify(e))),this.opt.noMatch(e))):(this.log("Ignoring invalid range: ".concat(JSON.stringify(e))),this.opt.noMatch(e)),{start:n,end:r,valid:o}}},{key:"checkWhitespaceRanges",value:function(e,t,n){var r,o=!0,i=n.length,a=t-i,s=parseInt(e.start,10)-a;return(r=(s=s>i?i:s)+parseInt(e.length,10))>i&&(r=i,this.log("End range automatically set to the max value of ".concat(i))),s<0||r-s<0||s>i||r>i?(o=!1,this.log("Invalid range: ".concat(JSON.stringify(e))),this.opt.noMatch(e)):""===n.substring(s,r).replace(/\s+/g,"")&&(o=!1,this.log("Skipping whitespace only range: "+JSON.stringify(e)),this.opt.noMatch(e)),{start:s,end:r,valid:o}}},{key:"getTextNodes",value:function(e){var t=this,n="",r=[];this.iterator.forEachNode(NodeFilter.SHOW_TEXT,function(e){r.push({start:n.length,end:(n+=e.textContent).length,node:e})},function(e){return t.matchesExclude(e.parentNode)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT},function(){e({value:n,nodes:r})})}},{key:"matchesExclude",value:function(e){return a.matches(e,this.opt.exclude.concat(["script","style","title","head","html"]))}},{key:"wrapRangeInTextNode",value:function(e,t,n){var r=this.opt.element?this.opt.element:"mark",o=e.splitText(t),i=o.splitText(n-t),a=document.createElement(r);return a.setAttribute("data-markjs","true"),this.opt.className&&a.setAttribute("class",this.opt.className),a.textContent=o.textContent,o.parentNode.replaceChild(a,o),i}},{key:"wrapRangeInMappedTextNode",value:function(e,t,n,r,o){var i=this;e.nodes.every(function(a,s){var c=e.nodes[s+1];if(void 0===c||c.start>t){if(!r(a.node))return!1;var u=t-a.start,l=(n>a.end?a.end:n)-a.start,h=e.value.substr(0,a.start),f=e.value.substr(l+a.start);if(a.node=i.wrapRangeInTextNode(a.node,u,l),e.value=h+f,e.nodes.forEach(function(t,n){n>=s&&(e.nodes[n].start>0&&n!==s&&(e.nodes[n].start-=l),e.nodes[n].end-=l)}),n-=l,o(a.node.previousSibling,a.start),!(n>a.end))return!1;t=a.end}return!0})}},{key:"wrapGroups",value:function(e,t,n,r){return r((e=this.wrapRangeInTextNode(e,t,t+n)).previousSibling),e}},{key:"separateGroups",value:function(e,t,n,r,o){for(var i=t.length,a=1;a-1&&r(t[a],e)&&(e=this.wrapGroups(e,s,t[a].length,o))}return e}},{key:"wrapMatches",value:function(e,t,n,r,o){var i=this,a=0===t?0:t+1;this.getTextNodes(function(t){t.nodes.forEach(function(t){var o;for(t=t.node;null!==(o=e.exec(t.textContent))&&""!==o[a];){if(i.opt.separateGroups)t=i.separateGroups(t,o,a,n,r);else{if(!n(o[a],t))continue;var s=o.index;if(0!==a)for(var c=1;c -
+

_(Enter URL of remote plugin file or local plugin file)_

diff --git a/emhttp/plugins/dynamix.plugin.manager/Plugins.page b/emhttp/plugins/dynamix.plugin.manager/Plugins.page index 661fd3c28..86811244e 100644 --- a/emhttp/plugins/dynamix.plugin.manager/Plugins.page +++ b/emhttp/plugins/dynamix.plugin.manager/Plugins.page @@ -145,7 +145,6 @@ function loadlist(id,check) { } $(function() { initlist(); - $('#plugin_tree').fileTree({root:'/boot/',top:'/boot/',filter:'plg'}, function(file) {$('#plugin_file').val(file);}); $('.tabs').append(""); $('.tabs').append(""); $('.tabs').append(""); diff --git a/emhttp/plugins/dynamix/DeviceInfo.page b/emhttp/plugins/dynamix/DeviceInfo.page index fa2332bf0..b6107af34 100644 --- a/emhttp/plugins/dynamix/DeviceInfo.page +++ b/emhttp/plugins/dynamix/DeviceInfo.page @@ -780,7 +780,8 @@ _(File system type)_: - style="display:none"> _(ReiserFS is deprecated, please use another file system)_! + + style="display:none"> _(ReiserFS is deprecated, please use another file system)_! @@ -862,32 +863,42 @@ _(Critical disk utilization threshold)_ (%): -
_(Pool Device Status)_
+
+ + _(Pool Device Status)_ + +
_(pool device stats)_: -: " . htmlspecialchars(shell_exec("/sbin/btrfs dev stats -T ".escapeshellarg("/mnt/$tag")), ENT_QUOTES, 'UTF-8') . ""; ?> +:
  -: +: + + -
_(Balance Status)_
+
+ + _(Balance Status)_ + +
_(btrfs filesystem usage)_: -: " . htmlspecialchars(shell_exec("/sbin/btrfs fi usage -T ".escapeshellarg("/mnt/$tag")), ENT_QUOTES, 'UTF-8') . ""; ?> +:
_(btrfs balance status)_: -: ".implode("\n", $balance_status).""?> +:
@@ -947,6 +958,7 @@ _(btrfs balance status)_: + _(Balance schedule)_: : _(Time of the day)_: -: -: +: + _(Block group usage)_ (%): :   -: +: + + +
-
_(Scrub Status)_
+
+ + _(Scrub Status)_ + +
_(btrfs scrub status)_: -: ".implode("\n", $scrub_status).""?> +:
@@ -1012,7 +1036,9 @@ _(btrfs scrub status)_:   -: +: + + :info_btrfs_scrub_help: @@ -1022,7 +1048,9 @@ _(btrfs scrub status)_:   -: *_(Running)_* +: + *_(Running)_* + :info_scrub_cancel_help: @@ -1030,7 +1058,10 @@ _(btrfs scrub status)_:   -: _(Scrub)_ _(is only available when the filesyestem is mounted)_ +: + + _(Scrub)_ _(is only available when the filesyestem is mounted)_ +
@@ -1067,36 +1098,48 @@ _(Day of the month)_: _(Time of the day)_: -: -: +: +   -: +: + + + -
_(Check Filesystem Status)_
+
+ + _(Check Filesystem Status)_ + +
_(btrfs check status)_: -: ".implode("\n", $check_status).""?> +:
@@ -1105,7 +1148,11 @@ _(btrfs check status)_:   -: _(Options (see Help))_ +: + + + _(Options (see Help))_ + :info_btrfs_check_help: @@ -1133,7 +1180,11 @@ _(btrfs check status)_:
-
_(Pool Status)_
+
+ + _(Pool Status)_ + +
@@ -1148,10 +1199,12 @@ _(zfs pool status)_:   -: - - - +: + + + + + :info_zfs_scrub_help: @@ -1169,11 +1222,20 @@ _(zfs pool status)_:   -: "._('Scrub')." "._('is only available when the filesyestem is mounted') : sprintf(_('See %s Settings'),ucfirst(prefix($tag)))?> +: + + + "._('Scrub')." "._('is only available when the filesyestem is mounted') : sprintf(_('See %s Settings'),ucfirst(prefix($tag)))?> + + -
_(Pool Information)_
+
+ + _(Pool Information)_ + +
_(zfs pool information)_: @@ -1183,7 +1245,11 @@ _(zfs pool information)_:

-
_(Scrub Schedule)_
+
+ + _(Scrub Schedule)_ + +
@@ -1215,37 +1281,49 @@ _(Day of the month)_: _(Time of the day)_: -: -: +: +   -: +: + + +
-
_(Check Filesystem Status)_
+
+ + _(Check Filesystem Status)_ + +
_(reiserfsck status)_: -: ".implode("\n", $check_status).""?> +:
@@ -1257,7 +1335,7 @@ _(reiserfsck status)_: : - _(Options (see Help))_ + _(Options (see Help))_ :info_reiserfs_check_help: @@ -1271,7 +1349,7 @@ _(reiserfsck status)_:   : - *_(Running)_* + *_(Running)_* :info_reiserfs_cancel_help: @@ -1282,20 +1360,24 @@ _(reiserfsck status)_:   : - **_(Check)_** _(is only available when array is Started in **Maintenance** mode)_. + **_(Check)_** _(is only available when array is Started in **Maintenance** mode)_. -
_(Check Filesystem Status)_
+
+ + _(Check Filesystem Status)_ + +
_(xfs_repair status)_: -: ".implode("\n", $check_status).""?> +:
@@ -1305,7 +1387,10 @@ _(xfs_repair status)_:   -: _(No file system corruption detected)_. +: + + _(No file system corruption detected)_. + :info_xfs_check_help: @@ -1317,7 +1402,10 @@ _(xfs_repair status)_:   -: _(File system corruption detected)_. +: + + _(File system corruption detected)_. + :info_xfs_check_help: @@ -1329,7 +1417,10 @@ _(xfs_repair status)_:   -: _(Dirty log detected)_. +: + + _(Dirty log detected)_. +

_(Note)_: _(While there is some risk, if it is not possible to first mount the filesystem to clear the log, zeroing it is the only option to try and repair the filesystem, and in most cases it results in little or no data loss)_.

@@ -1343,7 +1434,10 @@ _(xfs_repair status)_:   -: _(File system corruption fixed)_ +: + + _(File system corruption fixed)_ + :info_xfs_check_help: @@ -1353,7 +1447,10 @@ _(xfs_repair status)_:   -: *_(Running)_* +: + + *_(Running)_* + :info_xfs_cancel_help: @@ -1363,7 +1460,7 @@ _(xfs_repair status)_:   : - **_(Check)_** _(is only available when array is Started in **Maintenance** mode)_. + **_(Check)_** _(is only available when array is Started in **Maintenance** mode)_. diff --git a/emhttp/plugins/dynamix/DiskSettings.page b/emhttp/plugins/dynamix/DiskSettings.page index 0963d8566..2f1e10bac 100644 --- a/emhttp/plugins/dynamix/DiskSettings.page +++ b/emhttp/plugins/dynamix/DiskSettings.page @@ -299,7 +299,11 @@ _(Default critical SSD temperature threshold)_ (° -
_(Change encryption key)_
+
+ + _(Change encryption key)_ + +
@@ -315,7 +319,7 @@ _(Existing encryption key)_: :
+
@@ -340,7 +344,7 @@ _(Change encryption key)_: :
+
_(Type new passphrase)_: @@ -369,7 +373,11 @@ _(Select new keyfile)_: -
_(Global SMART Settings)_
+
+ + _(Global SMART Settings)_ + +
@@ -429,7 +437,13 @@ _(Default SMART attribute notifications)_:   -: >_(Attribute)_ = +: + > + + _(Attribute)_ = + + + :disk_default_smart_attribute_help: diff --git a/emhttp/plugins/dynamix/DisplaySettings.page b/emhttp/plugins/dynamix/DisplaySettings.page index dc7792666..1def58c8b 100644 --- a/emhttp/plugins/dynamix/DisplaySettings.page +++ b/emhttp/plugins/dynamix/DisplaySettings.page @@ -174,6 +174,12 @@ _(Terminal font size)_: :display_tty_size_help: +_(Show Terminal Button in header)_: +: + _(Number format)_: : - - - - _(Placement of Users menu)_: : +: _(AD short domain name)_: -: +: _(AD account login)_: -: +: _(AD account password)_: -: +:   -: - - - - +: + > + > +
-
+
_(AD initial owner)_: -: +: _(AD initial group)_: -: +:   : diff --git a/emhttp/plugins/dynamix/SecurityNFS.page b/emhttp/plugins/dynamix/SecurityNFS.page index ca111e255..d146ffe97 100644 --- a/emhttp/plugins/dynamix/SecurityNFS.page +++ b/emhttp/plugins/dynamix/SecurityNFS.page @@ -14,45 +14,53 @@ Cond="(($var['shareNFSEnabled']!='no') && (isset($name)?array_key_exists($name,$ * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. */ -?> - :nfs_security_help: -
-_(Read settings from)_ - -
-
-_(Write settings to)_ - +
+
+_(Read settings from)_ +: + + + + + + +_(Write settings to)_ +: + + + + +
+
@@ -73,27 +81,30 @@ _(Security)_:   -: +: -
+ + _(Rule)_: : :nfs_security_rules_help:   -: +: +
+
diff --git a/emhttp/plugins/dynamix/ShareEdit.page b/emhttp/plugins/dynamix/ShareEdit.page index af0952eb2..e8ff64e3a 100644 --- a/emhttp/plugins/dynamix/ShareEdit.page +++ b/emhttp/plugins/dynamix/ShareEdit.page @@ -13,8 +13,7 @@ Tag="share-alt-square" * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. */ -?> -done()"; exit; @@ -326,37 +325,16 @@ function direction() { /* global shares include/exclude. */ $myDisks = array_filter(array_diff(array_keys(array_filter($disks,'my_disks')), explode(',',$var['shareUserExclude'])), 'globalInclude'); + +$filteredShares = array_filter($shares, function($list) use ($name) { + return $list['name'] != $name || !$name; +}); ?> :share_edit_global1_help: :share_edit_global2_help: -
-
-_(Read settings from)_ - -
- - -
-_(Write settings to)_ - -
- -
":">"?> @@ -366,6 +344,40 @@ foreach ($rows as $row) echo $row; + +
+_(Read settings from)_ +: + + + + + + + +_(Write settings to)_ +: + + + + + + +
+ +
_(Share name)_: : _(Share name contains invalid characters for ZFS use)_ @@ -376,21 +388,20 @@ _(Comments)_: : :share_edit_comments_help: +
-
+
_(Minimum free space)_: -: +: :share_edit_free_space_help: -
_(Share status)_: : _(Share is empty)_ :share_edit_status_help: -
@@ -398,7 +409,6 @@ _(Share status)_: :  _(Share contains data)_ :share_edit_delete_help: -
@@ -574,8 +584,11 @@ _(Mover action)_:
- -: + +: diff --git a/emhttp/plugins/dynamix/Terminal.page b/emhttp/plugins/dynamix/Terminal.page index 7aeb348d4..0da228c56 100644 --- a/emhttp/plugins/dynamix/Terminal.page +++ b/emhttp/plugins/dynamix/Terminal.page @@ -30,7 +30,7 @@ function newTerminalOpen() { var referer = ''; setTimeout(function(){ // Only redirect to same origin or fallback to home - if (referer && referer.indexOf(window.location.origin) === 0 && basename(referer) != "Terminal") { + if (referer && referer.indexOf(window.location.origin) === 0 && basename(referer.split('?')[0].replace(/\/$/, '')) != "Terminal") { window.location.href = referer; } else { window.location.href = '/'; diff --git a/emhttp/plugins/dynamix/default.cfg b/emhttp/plugins/dynamix/default.cfg index c0689f732..b5635f29f 100644 --- a/emhttp/plugins/dynamix/default.cfg +++ b/emhttp/plugins/dynamix/default.cfg @@ -17,7 +17,7 @@ banner="" header="" background="" tabs="1" -terminalButton="no" +terminalButton="yes" users="Tasks:3" usage="0" text="1" diff --git a/emhttp/plugins/dynamix/include/DefaultPageLayout/MainContent.php b/emhttp/plugins/dynamix/include/DefaultPageLayout/MainContent.php index d4e69dd1f..81789a9a4 100644 --- a/emhttp/plugins/dynamix/include/DefaultPageLayout/MainContent.php +++ b/emhttp/plugins/dynamix/include/DefaultPageLayout/MainContent.php @@ -27,8 +27,8 @@ function processTitle($rawTitle) { '/\$([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*)/', function($matches) { return isset($GLOBALS[$matches[1]]) ? - htmlspecialchars((string)$GLOBALS[$matches[1]]) : - '$'.$matches[1]; + htmlspecialchars((string)$GLOBALS[$matches[1]]) : + '$'.$matches[1]; }, $title ); diff --git a/emhttp/plugins/dynamix/include/DefaultPageLayout/MainContentTabbed.php b/emhttp/plugins/dynamix/include/DefaultPageLayout/MainContentTabbed.php index b639e55bc..7f251740e 100644 --- a/emhttp/plugins/dynamix/include/DefaultPageLayout/MainContentTabbed.php +++ b/emhttp/plugins/dynamix/include/DefaultPageLayout/MainContentTabbed.php @@ -4,6 +4,7 @@ * Accessible, modern, and decoupled from non-tabbed logic. */ ?> +
- + '.generateContent($page)); + } continue; } $title = processTitle($page['Title']); @@ -47,7 +62,13 @@ '.generateContent($page)); ?> - +
diff --git a/emhttp/plugins/dynamix/sheets/Eth0.css b/emhttp/plugins/dynamix/sheets/Eth0.css index 9b9647406..b27ea1cdd 100644 --- a/emhttp/plugins/dynamix/sheets/Eth0.css +++ b/emhttp/plugins/dynamix/sheets/Eth0.css @@ -8,10 +8,6 @@ span.blue { span.green { color: var(--green-800); } -span.vshift { - margin-top: 0 !important; -} - /* Input styles */ input.gap { margin-right: 6px; diff --git a/emhttp/plugins/dynamix/sheets/Share.css b/emhttp/plugins/dynamix/sheets/Share.css deleted file mode 100644 index e9d15d558..000000000 --- a/emhttp/plugins/dynamix/sheets/Share.css +++ /dev/null @@ -1,41 +0,0 @@ -div.clone1 { - position: absolute; - right: 10px; - margin-top: 0; -} -div.clone2 { - position: absolute; - right: 10px; - margin-top: 48px; -} -span.input { - display: inline-block; - width: 330px; -} -input.clone { - margin-left: 8px; - margin-right: 0; -} -span.clone { - margin-right: 4px; -} -span.wrap { - display: inline-block; - width: 128px; -} -select.clone { - min-width: 123px; - max-width: 123px; - margin-right: 0; -} - - -.Theme--sidebar { - span.wrap { - width: 150px; - } - select.clone { - min-width: 145px; - max-width: 145px; - } -} diff --git a/emhttp/plugins/dynamix/styles/default-base.css b/emhttp/plugins/dynamix/styles/default-base.css index 8243e395a..ad2c5b34f 100644 --- a/emhttp/plugins/dynamix/styles/default-base.css +++ b/emhttp/plugins/dynamix/styles/default-base.css @@ -504,9 +504,6 @@ div.title { div.title span img { padding-right: 4px; } -div.title.shift { - margin-top: -30px; -} #menu { width: 100%; display: grid; @@ -554,7 +551,6 @@ div.title.shift { } @media (min-width: 768px) { .nav-tile.right { - text-align: right; justify-content: flex-end; } } @@ -1170,17 +1166,6 @@ span.status { display: inline-block; margin-left: auto; } -span.status.vhshift { - margin-top: 0; - /* leaving for reference, but should likely not be needed anymore */ - /* margin-right: -9px; */ -} -span.status.vshift { - margin-top: -16px; -} -span.status.hshift { - margin-right: -20px; -} span.diskinfo { float: left; clear: both; @@ -1305,19 +1290,19 @@ a.list { } } } -.tabs, + +.tabs { + display: flex; + align-items: center; + justify-content: space-between; + gap: .5rem; +} + .tabs-container { display: flex; flex-direction: row; align-items: center; gap: .5rem; -} - -.tabs { - justify-content: space-between; -} - -.tabs-container { overflow-x: auto; width: 100%; } @@ -1373,6 +1358,13 @@ a.list { padding-top: 1rem; } + /* Remove padding for forms inside TableContainer elements */ + .TableContainer form:first-of-type, + .TableContainer--widest form:first-of-type, + .TableContainer--no-min-width form:first-of-type { + padding-top: 0; + } + .shade form { padding-top: 0; } @@ -1754,12 +1746,23 @@ span#wlan0 { .shade { margin-top: 1rem; - padding: 1rem 0; + padding: 1rem; background-color: var(--shade-bg-color); + border-radius: .25rem; +} + +@media (min-width: 769px) { + .shade { + padding: 1rem 0; + } } /* TailwindCSS inspired utility classes */ +.relative { + position: relative; +} + .font-mono { font-family: bitstream, monospace; } @@ -1966,6 +1969,35 @@ span#wlan0 { .scrollbar-thin { scrollbar-width: thin; } + +@media (min-width: 1330px) { + .clone-settings { + position: absolute; + top: 0; + right: 0; + width: 40rem; + margin: 0; + padding: 3rem 1rem 0 0; + background-color: transparent; + + dl { + align-items: center; + gap: 1.5rem 1rem; + } + } + + .clone-settings-less-padding { + padding-top: 1rem; + } +} + +/* plugin overrides */ +/* fix UD title margin-top from overlapping tabs */ +div.title.ud, +div#title.ud { + margin-top: 0 !important; +} + /* * Using CSS Nesting, to narrow down the scope of the styles to the .Theme--sidebar class. * This allows us to have default-azure & default-gray set css variables @@ -2373,9 +2405,6 @@ span#wlan0 { div.title:first-of-type { margin-top: 0; } - div.title.shift { - margin-top: -12px; - } .usage-bar { position: relative; diff --git a/emhttp/plugins/dynamix/styles/default-dynamix.css b/emhttp/plugins/dynamix/styles/default-dynamix.css index 5eee0284b..34986f044 100644 --- a/emhttp/plugins/dynamix/styles/default-dynamix.css +++ b/emhttp/plugins/dynamix/styles/default-dynamix.css @@ -1585,12 +1585,27 @@ div.icon-zip { outline: none; display: inline-block; cursor: pointer; + width: 100%; padding: 1px 0; } .ui-dropdownchecklist-selector-wrapper { vertical-align: middle; font-size: 0; + width: 100%; + + /** + * override the defined with set by the jquery library + * + * @note - commented out b/c it causes overflow issues if too many items are selected + */ + /* .ui-dropdownchecklist-selector { + width: 100% !important; + } */ + + .ui-dropdownchecklist-text { + padding-left: .5rem; + } } .ui-dropdownchecklist-dropcontainer {