feat: VivesPOS landing on Winter CMS 1.2 — theme + plugin + Dockerfile
Some checks are pending
Module sub-split / Sub-split (push) Waiting to run
Some checks are pending
Module sub-split / Sub-split (push) Waiting to run
- Base: wintercms/winter branch 1.2 (full framework) - Theme vivespos: Canvas 7 + Bootstrap 5 CDN, custom CSS - Layout: deferred GTM/GA4 tracking, JSON-LD SoftwareApplication - Partials: hero (offline-first), features, modes (offline/nube toggle), screenshots, pricing (3 planes), comparison, FAQ, CTA - Plugin VivesPOS.Site with ContactForm - Dockerfile: PHP 8.2 Apache, port 80, healthcheck - Added winter/wn-pages, blog, sitemap, seo plugins - Active theme set to vivespos
This commit is contained in:
52
modules/system/assets/ui/js/foundation.controlutils.js
vendored
Normal file
52
modules/system/assets/ui/js/foundation.controlutils.js
vendored
Normal file
@@ -0,0 +1,52 @@
|
||||
/*
|
||||
* Winter JavaScript foundation library.
|
||||
*
|
||||
* Utility functions for working back-end client-side UI controls.
|
||||
*
|
||||
* Usage examples:
|
||||
*
|
||||
* $.wn.foundation.controlUtils.markDisposable(el)
|
||||
* $.wn.foundation.controlUtils.disposeControls(container)
|
||||
*
|
||||
*/
|
||||
+function ($) { "use strict";
|
||||
if ($.wn === undefined)
|
||||
$.wn = {}
|
||||
if ($.oc === undefined)
|
||||
$.oc = $.wn
|
||||
|
||||
if ($.wn.foundation === undefined)
|
||||
$.wn.foundation = {}
|
||||
|
||||
var ControlUtils = {
|
||||
markDisposable: function(el) {
|
||||
el.setAttribute('data-disposable', '')
|
||||
},
|
||||
|
||||
/*
|
||||
* Destroys all disposable controls in a container.
|
||||
* The disposable controls should watch the dispose-control
|
||||
* event.
|
||||
*/
|
||||
disposeControls: function(container) {
|
||||
var controls = container.querySelectorAll('[data-disposable]')
|
||||
|
||||
for (var i=0, len=controls.length; i<len; i++)
|
||||
$(controls[i]).triggerHandler('dispose-control')
|
||||
|
||||
if (container.hasAttribute('data-disposable'))
|
||||
$(container).triggerHandler('dispose-control')
|
||||
}
|
||||
}
|
||||
|
||||
$.wn.foundation.controlUtils = ControlUtils;
|
||||
|
||||
$(document).on('ajaxBeforeReplace', function(ev){
|
||||
// Automatically dispose controls in an element
|
||||
// before the element contents is replaced.
|
||||
// The ajaxBeforeReplace event is triggered in
|
||||
// framework.js
|
||||
|
||||
$.wn.foundation.controlUtils.disposeControls(ev.target)
|
||||
})
|
||||
}(window.jQuery);
|
||||
Reference in New Issue
Block a user