vizor_styler 1.1.5 → 1.1.8

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/README.md CHANGED
@@ -1,144 +1,144 @@
1
- # vizor_styler
2
-
3
-
4
- Lib template for the VIZOR ENGINE PLATFORM
5
-
6
-
7
-
8
- # VIZOR Collaborator instructions
9
-
10
-
11
- FIRST TIME :
12
-
13
-
14
- 1. Clone the project:
15
-
16
- git clone https://github.com/your-username/your-repository.git
17
-
18
-
19
-
20
- NOTA : Al clonar el template y crear una nueva libreria
21
- usar rm -rf .git
22
- para desvincular el proyecto
23
- y crear otro repositorio en github.
24
-
25
-
26
-
27
-
28
- 2. Modify:
29
-
30
- Make your changes in the codebase.
31
-
32
- 3. Create a local branch:
33
-
34
- - NOTA : Como nombre del branch se puede usar la versión,
35
- ejemplo : release-vX.Y.Z
36
-
37
- Colocar en CHANGELOG.md el detalle de los cambios realizados:
38
-
39
- ```bash
40
- git checkout -b feature-branch-name
41
- ```
42
-
43
-
44
-
45
- 4. Add and commit changes:
46
-
47
- git add .
48
-
49
- git commit -m "Description of the changes"
50
-
51
- 5. Push the branch:
52
-
53
- git push origin feature-branch-name
54
-
55
- 6. Create a pull request on GitHub.
56
-
57
- 7. Ask the owner to accept and merge
58
-
59
-
60
-
61
- NEXT STEPS (Continous Development)
62
-
63
- 1. pull to have the lastest changes
64
-
65
- git checkout main
66
- git pull origin main
67
-
68
-
69
- 2. create a new branch (use a name that clearly comunicate the featur you ar working on)
70
-
71
- git checkout -b new-feature-branch
72
-
73
-
74
- 3. Make your changes in the codebase.
75
-
76
- 4. push the new changes
77
-
78
- git add .
79
- git commit -m "Description of changes"
80
- git push origin new-feature-branch
81
-
82
-
83
-
84
-
85
- # Managing Versioning
86
-
87
- Determine the version update type:
88
- Decide whether the changes constitute a major, minor, or patch update based on the Semantic
89
-
90
- Versioning guidelines:
91
-
92
- Major: Incompatible API changes.
93
- Minor: Backward-compatible functionality.
94
- Patch: Backward-compatible bug fixes.
95
-
96
- Update the version number:
97
- Update the version number in the relevant files (e.g., package.json for Node.js projects) based on the determined version update type.
98
-
99
- 1. Create a release branch:
100
-
101
- git checkout main
102
- git pull origin main
103
- git checkout -b release-vX.Y.Z
104
- Update the changelog:
105
- Document the changes in a CHANGELOG.md file, outlining the new features, bug fixes, and other relevant information for the release.
106
-
107
- 2. Commit the version update and changelog:
108
-
109
- git add .
110
- git commit -m "Bump version to vX.Y.Z and update changelog"
111
-
112
- 3. Push the release branch:
113
-
114
- git push origin release-vX.Y.Z
115
-
116
- 4. Create a pull request for the release branch:
117
-
118
- 5. Create a pull request to merge the release branch into the main branch.
119
-
120
- 6. Merge the pull request:
121
-
122
- Once reviewed and approved, merge the pull request.
123
-
124
- 7. Tag the release:
125
-
126
- 8. After merging, create a tag for the new release:
127
-
128
- git checkout main
129
- git pull origin main
130
- git tag -a vX.Y.Z -m "Release version vX.Y.Z"
131
- git push origin vX.Y.Z
132
-
133
-
134
- 9. Create a release on GitHub:
135
-
136
- Go to the GitHub repository, navigate to the "Releases" section, and create a new release using the created tag. Provide the release notes based on the changelog.
137
-
138
-
139
- By following these steps, you'll maintain a well-organized versioning system, ensuring that the codebase remains structured and that changes are properly documented and released.
140
-
141
-
142
-
143
-
144
- # vizor_lib_template
1
+ # vizor_styler
2
+
3
+
4
+ Lib template for the VIZOR ENGINE PLATFORM
5
+
6
+
7
+
8
+ # VIZOR Collaborator instructions
9
+
10
+
11
+ FIRST TIME :
12
+
13
+
14
+ 1. Clone the project:
15
+
16
+ git clone https://github.com/your-username/your-repository.git
17
+
18
+
19
+
20
+ NOTA : Al clonar el template y crear una nueva libreria
21
+ usar rm -rf .git
22
+ para desvincular el proyecto
23
+ y crear otro repositorio en github.
24
+
25
+
26
+
27
+
28
+ 2. Modify:
29
+
30
+ Make your changes in the codebase.
31
+
32
+ 3. Create a local branch:
33
+
34
+ - NOTA : Como nombre del branch se puede usar la versión,
35
+ ejemplo : release-vX.Y.Z
36
+
37
+ Colocar en CHANGELOG.md el detalle de los cambios realizados:
38
+
39
+ ```bash
40
+ git checkout -b feature-branch-name
41
+ ```
42
+
43
+
44
+
45
+ 4. Add and commit changes:
46
+
47
+ git add .
48
+
49
+ git commit -m "Description of the changes"
50
+
51
+ 5. Push the branch:
52
+
53
+ git push origin feature-branch-name
54
+
55
+ 6. Create a pull request on GitHub.
56
+
57
+ 7. Ask the owner to accept and merge
58
+
59
+
60
+
61
+ NEXT STEPS (Continous Development)
62
+
63
+ 1. pull to have the lastest changes
64
+
65
+ git checkout main
66
+ git pull origin main
67
+
68
+
69
+ 2. create a new branch (use a name that clearly comunicate the featur you ar working on)
70
+
71
+ git checkout -b new-feature-branch
72
+
73
+
74
+ 3. Make your changes in the codebase.
75
+
76
+ 4. push the new changes
77
+
78
+ git add .
79
+ git commit -m "Description of changes"
80
+ git push origin new-feature-branch
81
+
82
+
83
+
84
+
85
+ # Managing Versioning
86
+
87
+ Determine the version update type:
88
+ Decide whether the changes constitute a major, minor, or patch update based on the Semantic
89
+
90
+ Versioning guidelines:
91
+
92
+ Major: Incompatible API changes.
93
+ Minor: Backward-compatible functionality.
94
+ Patch: Backward-compatible bug fixes.
95
+
96
+ Update the version number:
97
+ Update the version number in the relevant files (e.g., package.json for Node.js projects) based on the determined version update type.
98
+
99
+ 1. Create a release branch:
100
+
101
+ git checkout main
102
+ git pull origin main
103
+ git checkout -b release-vX.Y.Z
104
+ Update the changelog:
105
+ Document the changes in a CHANGELOG.md file, outlining the new features, bug fixes, and other relevant information for the release.
106
+
107
+ 2. Commit the version update and changelog:
108
+
109
+ git add .
110
+ git commit -m "Bump version to vX.Y.Z and update changelog"
111
+
112
+ 3. Push the release branch:
113
+
114
+ git push origin release-vX.Y.Z
115
+
116
+ 4. Create a pull request for the release branch:
117
+
118
+ 5. Create a pull request to merge the release branch into the main branch.
119
+
120
+ 6. Merge the pull request:
121
+
122
+ Once reviewed and approved, merge the pull request.
123
+
124
+ 7. Tag the release:
125
+
126
+ 8. After merging, create a tag for the new release:
127
+
128
+ git checkout main
129
+ git pull origin main
130
+ git tag -a vX.Y.Z -m "Release version vX.Y.Z"
131
+ git push origin vX.Y.Z
132
+
133
+
134
+ 9. Create a release on GitHub:
135
+
136
+ Go to the GitHub repository, navigate to the "Releases" section, and create a new release using the created tag. Provide the release notes based on the changelog.
137
+
138
+
139
+ By following these steps, you'll maintain a well-organized versioning system, ensuring that the codebase remains structured and that changes are properly documented and released.
140
+
141
+
142
+
143
+
144
+ # vizor_lib_template
@@ -1,16 +1,16 @@
1
- .info-window-content {
2
- position: absolute;
3
- top: 50%;
4
- right: 0;
5
- transform: translateY(-50%);
6
- padding: 15px;
7
- font-size: 16px;
8
- color: #fff;
9
- background: rgba(0, 0, 0, 0.8);
10
- border-radius: 5px;
11
- border: 1px solid #ddd;
12
- width: 300px;
13
- height: 200px;
14
- text-align: center;
15
- box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
16
- }
1
+ .info-window-content {
2
+ position: absolute;
3
+ top: 50%;
4
+ right: 0;
5
+ transform: translateY(-50%);
6
+ padding: 15px;
7
+ font-size: 16px;
8
+ color: #fff;
9
+ background: rgba(0, 0, 0, 0.8);
10
+ border-radius: 5px;
11
+ border: 1px solid #ddd;
12
+ width: 300px;
13
+ height: 200px;
14
+ text-align: center;
15
+ box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
16
+ }
@@ -1 +1 @@
1
- var e={};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},t(e)}function n(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o,r,l,i,a=[],c=!0,u=!1;try{if(l=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(o=l.call(n)).done)&&(a.push(o.value),a.length!==t);c=!0);}catch(e){u=!0,r=e}finally{try{if(!c&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(u)throw r}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return o(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=Array(t);n<t;n++)o[n]=e[n];return o}function r(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,l(o.key),o)}}function l(e){var n=function(e,n){if("object"!=t(e)||!e)return e;var o=e[Symbol.toPrimitive];if(void 0!==o){var r=o.call(e,n||"default");if("object"!=t(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===n?String:Number)(e)}(e,"string");return"symbol"==t(n)?n:n+""}e.d=(t,n)=>{for(var o in n)e.o(n,o)&&!e.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:n[o]})},e.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var i=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),console.log("instance created")}return t=e,l=[{key:"my_static_method",value:function(){return"return of static method"}},{key:"setStyle",value:function(e,t){var o=document.getElementById("".concat(e,"-style"));o||((o=document.createElement("style")).id="".concat(e,"-style"),document.head.appendChild(o));var r="\n ".concat(e," {\n ").concat(Object.entries(t).map(function(e){var t=n(e,2),o=t[0],r=t[1];return"".concat(o,": ").concat(r,";")}).join(" "),"\n }\n ");o.innerHTML=r}},{key:"updateStyle",value:function(e,t){var o,r=document.getElementById("".concat(e,"-style"));if(!r)return console.warn("Style for ".concat(e," not found. Creating new one.")),void createOrModifyStyles(e,t);var l=null===(o=r.innerHTML.match(new RegExp("".concat(e," {([^}]*)}"))))||void 0===o?void 0:o[1].split(";").filter(Boolean).map(function(e){return e.trim().split(":").map(function(e){return e.trim()})}),i=Object.fromEntries(l);Object.assign(i,t);var a="\n ".concat(e," {\n ").concat(Object.entries(i).map(function(e){var t=n(e,2),o=t[0],r=t[1];return"".concat(o,": ").concat(r,";")}).join(" "),"\n }\n ");r.innerHTML=a}},{key:"addLabelToBody",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"black",o=document.createElement(2===t?"h2":"h1");o.textContent=e,o.style.color=n,document.body.appendChild(o)}},{key:"replaceImageInDiv",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:200;console.log("reemplazado");var o=document.getElementById("header");o&&(o.innerHTML='<img src="'.concat(t,'" alt="New Logo" width="').concat(n,'px">'))}},{key:"setLogo",value:function(t,n){e.replaceImageInDiv("header",t,n)}},{key:"setBackgroundColor",value:function(e){document.body.style.backgroundColor=e}},{key:"setTitle",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"white",o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;e.addLabelToBody(t,o,n)}},{key:"setSelectorColor",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"rgba(255, 255, 255, 0.2)";e.setStyle(".selection-wrapper path",{fill:t})}},{key:"goFullScreen",value:function(){var e=document.documentElement;e.requestFullscreen?e.requestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.webkitRequestFullscreen?e.webkitRequestFullscreen():e.msRequestFullscreen?e.msRequestFullscreen():console.log("Fullscreen API is not supported in this browser.")}},{key:"SetWindowColorTheme",value:function(e){e||(document.querySelectorAll(".ui-resizable-handle.ui-resizable-se.ui-icon.ui-icon-gripsmall-diagonal-se").forEach(function(e){for(var t=[],n=e.parentElement;n;)"div"===n.tagName.toLowerCase()&&t.push(n),n=n.parentElement;t.forEach(function(e){e.style.border="rgba(61, 87, 113, 0.8)",e.style.borderStyle="solid",e.style.borderWidth="1px",e.style.boxShadow="rgba(0, 0, 0, 0.5) 4px 4px 27px"})}),document.querySelectorAll(".top-bar").forEach(function(e){e.style.backgroundColor="#3F4A67",e.style.fontSize="12px",e.style.margin="0px",e.style.padding="9px",e.style.color="#73BDDA",e.style.border="#547697",e.style.borderStyle="solid",e.style.borderWidth="1px"}))}},{key:"createHeader",value:function(e,t,n){console.log("createHeader",t);var o,r=document.createElement("p"),l=window.location.hostname;o=t||(l.includes("ert.mx")?"https://qh4wzmakbgwqvzku.public.blob.vercel-storage.com/b2cff9fb-a38e-4a11-a540-32d833b7f117/icon%20ERT-bXJP7FInYZHqvu5mKKvegGZ6tXal69.png":"https://dev.vizor.studio/_next/image?url=%2Fmini_logo_transparent.png&w=128&q=75");var i="#686b9b";n&&(i=n),r.innerHTML='\n <div style="\n position: fixed;\n top: 5px;\n left: 20px;\n right: 20px;\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 9px 0px;\n background-color:'.concat(i,' ;\n color: white;\n border-radius: 8px;\n box-sizing: border-box;\n ">\n <div style="display: flex; align-items: center; gap: 12px;">\n <img src="').concat(o,'"\n alt="menu"\n style="width: 54px;">\n <div>\n <div style="font-size: 0.9rem; font-weight: 600;">\n ').concat(e,"\n </div>\n </div>\n </div>\n </div>\n"),document.body.appendChild(r)}}],(o=[{key:"doSomething",value:function(){console.log("done")}}])&&r(t.prototype,o),l&&r(t,l),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,o,l}();export{i as vi_Styler};
1
+ var e={282:()=>{}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var r={};function o(e){return o="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},o(e)}function i(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,l,a=[],c=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);c=!0);}catch(e){u=!0,o=e}finally{try{if(!c&&null!=n.return&&(l=n.return(),Object(l)!==l))return}finally{if(u)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return l(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?l(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,c(r.key),r)}}function c(e){var t=function(e,t){if("object"!=o(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=o(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==o(t)?t:t+""}n.d(r,{Y:()=>u,u:()=>s.withBackgroundColorPicker});var u=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),console.log("instance created")}return t=e,r=[{key:"my_static_method",value:function(){return"return of static method"}},{key:"setStyle",value:function(e,t){var n=document.getElementById("".concat(e,"-style"));n||((n=document.createElement("style")).id="".concat(e,"-style"),document.head.appendChild(n));var r="\n ".concat(e," {\n ").concat(Object.entries(t).map((function(e){var t=i(e,2),n=t[0],r=t[1];return"".concat(n,": ").concat(r,";")})).join(" "),"\n }\n ");n.innerHTML=r}},{key:"updateStyle",value:function(e,t){var n,r=document.getElementById("".concat(e,"-style"));if(!r)return console.warn("Style for ".concat(e," not found. Creating new one.")),void createOrModifyStyles(e,t);var o=null===(n=r.innerHTML.match(new RegExp("".concat(e," {([^}]*)}"))))||void 0===n?void 0:n[1].split(";").filter(Boolean).map((function(e){return e.trim().split(":").map((function(e){return e.trim()}))})),l=Object.fromEntries(o);Object.assign(l,t);var a="\n ".concat(e," {\n ").concat(Object.entries(l).map((function(e){var t=i(e,2),n=t[0],r=t[1];return"".concat(n,": ").concat(r,";")})).join(" "),"\n }\n ");r.innerHTML=a}},{key:"addLabelToBody",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"black",r=document.createElement(2===t?"h2":"h1");r.textContent=e,r.style.color=n,document.body.appendChild(r)}},{key:"replaceImageInDiv",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:200;console.log("reemplazado");var r=document.getElementById("header");r&&(r.innerHTML='<img src="'.concat(t,'" alt="New Logo" width="').concat(n,'px">'))}},{key:"setLogo",value:function(t,n){e.replaceImageInDiv("header",t,n)}},{key:"setBackgroundColor",value:function(e){document.body.style.backgroundColor=e}},{key:"setTitle",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"white",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;e.addLabelToBody(t,r,n)}},{key:"setSelectorColor",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"rgba(255, 255, 255, 0.2)";e.setStyle(".selection-wrapper path",{fill:t})}},{key:"goFullScreen",value:function(){var e=document.documentElement;e.requestFullscreen?e.requestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.webkitRequestFullscreen?e.webkitRequestFullscreen():e.msRequestFullscreen?e.msRequestFullscreen():console.log("Fullscreen API is not supported in this browser.")}},{key:"SetWindowColorTheme",value:function(e){e||(document.querySelectorAll(".ui-resizable-handle.ui-resizable-se.ui-icon.ui-icon-gripsmall-diagonal-se").forEach((function(e){for(var t=[],n=e.parentElement;n;)"div"===n.tagName.toLowerCase()&&t.push(n),n=n.parentElement;t.forEach((function(e){e.style.border="rgba(61, 87, 113, 0.8)",e.style.borderStyle="solid",e.style.borderWidth="1px",e.style.boxShadow="rgba(0, 0, 0, 0.5) 4px 4px 27px"}))})),document.querySelectorAll(".top-bar").forEach((function(e){e.style.backgroundColor="#3F4A67",e.style.fontSize="12px",e.style.margin="0px",e.style.padding="9px",e.style.color="#73BDDA",e.style.border="#547697",e.style.borderStyle="solid",e.style.borderWidth="1px"})))}},{key:"createHeader",value:function(e,t,n){console.log("createHeader",t);var r,o=document.createElement("p"),i=window.location.hostname;r=t||(i.includes("ert.mx")?"https://qh4wzmakbgwqvzku.public.blob.vercel-storage.com/b2cff9fb-a38e-4a11-a540-32d833b7f117/icon%20ERT-bXJP7FInYZHqvu5mKKvegGZ6tXal69.png":"https://dev.vizor.studio/_next/image?url=%2Fmini_logo_transparent.png&w=128&q=75");var l="#686b9b";n&&(l=n),o.innerHTML='\n <div style="\n position: fixed;\n top: 5px;\n left: 20px;\n right: 20px;\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 9px 0px;\n background-color:'.concat(l,' ;\n color: white;\n border-radius: 8px;\n box-sizing: border-box;\n ">\n <div style="display: flex; align-items: center; gap: 12px;">\n <img src="').concat(r,'"\n alt="menu"\n style="width: 54px;">\n <div>\n <div style="font-size: 0.9rem; font-weight: 600;">\n ').concat(e,"\n </div>\n </div>\n </div>\n </div>\n"),document.body.appendChild(o)}},{key:"injectStyles",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.replace,o=void 0!==r&&r,i=n.target,l=void 0===i?document.head:i;if("string"!=typeof e||!e.trim())throw new TypeError("injectStyles: id must be a non-empty string.");if("string"!=typeof t)throw new TypeError("injectStyles: css must be a string.");if(!(l instanceof Element))throw new TypeError("injectStyles: target must be a DOM element.");var a=e.trim(),c=document.getElementById(a);if(c){if(!(c instanceof HTMLStyleElement))throw new Error('injectStyles: an element with id "'.concat(a,'" already exists and is not a <style> element.'));return o&&(c.textContent=t),c}var u=document.createElement("style");return u.id=a,u.textContent=t,l.appendChild(u),u}}],(n=[{key:"doSomething",value:function(){console.log("done")}}])&&a(t.prototype,n),r&&a(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,n,r}(),s=n(282),d=r.Y,y=r.u;export{d as vi_Styler,y as withBackgroundColorPicker};
@@ -1,2 +1,2 @@
1
- /*! For license information please see vizor_styler.min.js.LICENSE.txt */
1
+ /*! For license information please see vizor_styler.min.js.LICENSE.txt */
2
2
  !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.vizor_styler=e():t.vizor_styler=e()}(this,(()=>(()=>{"use strict";var t={d:(e,r)=>{for(var n in r)t.o(r,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:r[n]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function n(){n=function(){return e};var t,e={},o=Object.prototype,i=o.hasOwnProperty,a=Object.defineProperty||function(t,e,r){t[e]=r.value},c="function"==typeof Symbol?Symbol:{},u=c.iterator||"@@iterator",l=c.asyncIterator||"@@asyncIterator",f=c.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function h(t,e,r,n){var o=e&&e.prototype instanceof b?e:b,i=Object.create(o.prototype),c=new G(n||[]);return a(i,"_invoke",{value:P(t,r,c)}),i}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=h;var y="suspendedStart",v="suspendedYield",d="executing",m="completed",g={};function b(){}function w(){}function x(){}var j={};s(j,u,(function(){return this}));var E=Object.getPrototypeOf,L=E&&E(E(q([])));L&&L!==o&&i.call(L,u)&&(j=L);var _=x.prototype=b.prototype=Object.create(j);function S(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function n(o,a,c,u){var l=p(t[o],t,a);if("throw"!==l.type){var f=l.arg,s=f.value;return s&&"object"==r(s)&&i.call(s,"__await")?e.resolve(s.__await).then((function(t){n("next",t,c,u)}),(function(t){n("throw",t,c,u)})):e.resolve(s).then((function(t){f.value=t,c(f)}),(function(t){return n("throw",t,c,u)}))}u(l.arg)}var o;a(this,"_invoke",{value:function(t,r){function i(){return new e((function(e,o){n(t,r,e,o)}))}return o=o?o.then(i,i):i()}})}function P(e,r,n){var o=y;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===m){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=k(c,n);if(u){if(u===g)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===y)throw o=m,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=p(e,r,n);if("normal"===l.type){if(o=n.done?m:v,l.arg===g)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=m,n.method="throw",n.arg=l.arg)}}}function k(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,k(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),g;var i=p(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,g;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,g):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,g)}function T(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function G(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(T,this),this.reset(!0)}function q(e){if(e||""===e){var n=e[u];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(i.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(r(e)+" is not iterable")}return w.prototype=x,a(_,"constructor",{value:x,configurable:!0}),a(x,"constructor",{value:w,configurable:!0}),w.displayName=s(x,f,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,x):(t.__proto__=x,s(t,f,"GeneratorFunction")),t.prototype=Object.create(_),t},e.awrap=function(t){return{__await:t}},S(O.prototype),s(O.prototype,l,(function(){return this})),e.AsyncIterator=O,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new O(h(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},S(_),s(_,f,"Generator"),s(_,u,(function(){return this})),s(_,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=q,G.prototype={constructor:G,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&i.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],c=a.completion;if("root"===a.tryLoc)return n("end");if(a.tryLoc<=this.prev){var u=i.call(a,"catchLoc"),l=i.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return n(a.catchLoc,!0);if(this.prev<a.finallyLoc)return n(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return n(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return n(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&i.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var o=n;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,g):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),g},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),g}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:q(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),g}},e}function o(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function i(t){return new Promise((function(e,r){var n=document.createElement("script");n.src=t,n.onload=function(){return e(t)},n.onerror=function(){return r(new Error("Failed to load script: ".concat(t)))},document.body.appendChild(n)}))}function a(){return c.apply(this,arguments)}function c(){var t;return t=n().mark((function t(){return n().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return console.log("Initializing vizor_styler"),t.prev=1,t.next=4,i("https://code.jquery.com/jquery-3.6.0.min.js");case 4:return t.next=6,i("https://code.jquery.com/ui/1.12.1/jquery-ui.min.js");case 6:e="https://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css",r=void 0,(r=document.createElement("link")).rel="stylesheet",r.href=e,document.head.appendChild(r),t.next=12;break;case 9:t.prev=9,t.t0=t.catch(1),console.error("Error initializing vizor_styler:",t.t0);case 12:case"end":return t.stop()}var e,r}),t,null,[[1,9]])})),c=function(){var e=this,r=arguments;return new Promise((function(n,i){var a=t.apply(e,r);function c(t){o(a,n,i,c,u,"next",t)}function u(t){o(a,n,i,c,u,"throw",t)}c(void 0)}))},c.apply(this,arguments)}function u(t){return u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},u(t)}function l(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,f(n.key),n)}}function f(t){var e=function(t,e){if("object"!=u(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=u(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==u(e)?e:e+""}t.r(e),t.d(e,{init:()=>a,vi_TestLib:()=>s});var s=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),console.log("instance created")},r=[{key:"my_static_method",value:function(){return"return of static method"}}],(e=[{key:"doSomething",value:function(){console.log("done")}}])&&l(t.prototype,e),r&&l(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e,r}();return e})()));
@@ -1 +1 @@
1
- /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
1
+ /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
package/package.json CHANGED
@@ -1,33 +1,33 @@
1
- {
2
- "name": "vizor_styler",
3
- "version": "1.1.5",
4
- "description": "create and modify css styles",
5
- "main": "dist/vizor_styler.min.js",
6
- "module": "dist/vizor_styler.min.js",
7
- "exports": {
8
- ".": "./dist/vizor_styler.min.js"
9
- },
10
-
11
- "files":[
12
- "README.md",
13
- "dist"
14
- ],
15
- "scripts": {
16
- "build": "webpack --mode production",
17
- "test": "echo \"Error: no test specified\" && exit 1"
18
- },
19
- "author": "Esteban Ortiz",
20
- "license": "ISC",
21
- "devDependencies": {
22
- "@babel/core": "^7.25.2",
23
- "@babel/preset-env": "^7.25.3",
24
- "babel-loader": "^9.1.3",
25
- "webpack": "^5.93.0",
26
- "webpack-cli": "^5.1.4",
27
- "webpack-dev-server": "^5.0.4"
28
- },
29
- "peerDependencies": {
30
- "jquery": "^3.7.1",
31
- "jquery-ui": "^1.13.3"
32
- }
33
- }
1
+ {
2
+ "name": "vizor_styler",
3
+ "version": "1.1.8",
4
+ "description": "create and modify css styles",
5
+ "main": "dist/vizor_styler.min.js",
6
+ "module": "dist/vizor_styler.min.js",
7
+ "exports": {
8
+ ".": "./dist/vizor_styler.min.js"
9
+ },
10
+
11
+ "files":[
12
+ "README.md",
13
+ "dist"
14
+ ],
15
+ "scripts": {
16
+ "build": "webpack --mode production",
17
+ "test": "echo \"Error: no test specified\" && exit 1"
18
+ },
19
+ "author": "Esteban Ortiz",
20
+ "license": "ISC",
21
+ "devDependencies": {
22
+ "@babel/core": "^7.25.2",
23
+ "@babel/preset-env": "^7.25.3",
24
+ "babel-loader": "^9.1.3",
25
+ "webpack": "^5.93.0",
26
+ "webpack-cli": "^5.1.4",
27
+ "webpack-dev-server": "^5.0.4"
28
+ },
29
+ "peerDependencies": {
30
+ "jquery": "^3.7.1",
31
+ "jquery-ui": "^1.13.3"
32
+ }
33
+ }