@everymatrix/helper-tabs 1.32.4 → 1.33.0

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.
Files changed (52) hide show
  1. package/dist/cjs/helper-tab_2.cjs.entry.js +136 -0
  2. package/dist/cjs/helper-tabs.cjs.js +19 -0
  3. package/dist/cjs/index-c1f39e41.js +1179 -0
  4. package/dist/cjs/index.cjs.js +2 -0
  5. package/dist/cjs/loader.cjs.js +21 -0
  6. package/dist/collection/collection-manifest.json +13 -0
  7. package/dist/collection/components/helper-tab/helper-tab.css +9 -0
  8. package/dist/collection/components/helper-tab/helper-tab.js +150 -0
  9. package/dist/collection/components/helper-tabs/helper-tabs.css +34 -0
  10. package/dist/collection/components/helper-tabs/helper-tabs.js +247 -0
  11. package/dist/collection/index.js +1 -0
  12. package/dist/collection/utils/utils.js +33 -0
  13. package/dist/components/helper-tab.d.ts +11 -0
  14. package/dist/components/helper-tab.js +6 -0
  15. package/dist/components/helper-tab2.js +86 -0
  16. package/dist/components/helper-tabs.d.ts +11 -0
  17. package/dist/components/helper-tabs.js +105 -0
  18. package/dist/components/index.d.ts +26 -0
  19. package/dist/components/index.js +1 -0
  20. package/dist/esm/helper-tab_2.entry.js +131 -0
  21. package/dist/esm/helper-tabs.js +17 -0
  22. package/dist/esm/index-77d38aa8.js +1153 -0
  23. package/dist/esm/index.js +1 -0
  24. package/dist/esm/loader.js +17 -0
  25. package/dist/esm/polyfills/core-js.js +11 -0
  26. package/dist/esm/polyfills/css-shim.js +1 -0
  27. package/dist/esm/polyfills/dom.js +79 -0
  28. package/dist/esm/polyfills/es5-html-element.js +1 -0
  29. package/dist/esm/polyfills/index.js +34 -0
  30. package/dist/esm/polyfills/system.js +6 -0
  31. package/dist/helper-tabs/helper-tabs.esm.js +1 -0
  32. package/dist/helper-tabs/index.esm.js +0 -0
  33. package/dist/helper-tabs/p-b489f120.js +1 -0
  34. package/dist/helper-tabs/p-db41ef75.entry.js +1 -0
  35. package/dist/index.cjs.js +1 -0
  36. package/dist/index.js +1 -0
  37. package/dist/stencil.config.js +22 -0
  38. package/dist/types/Users/adrian.pripon/Documents/Work/widgets-stencil/packages/helper-tabs/.stencil/packages/helper-tabs/stencil.config.d.ts +2 -0
  39. package/dist/types/components/helper-tab/helper-tab.d.ts +26 -0
  40. package/dist/types/components/helper-tabs/helper-tabs.d.ts +46 -0
  41. package/dist/types/components.d.ts +154 -0
  42. package/dist/types/index.d.ts +1 -0
  43. package/dist/types/stencil-public-runtime.d.ts +1565 -0
  44. package/dist/types/utils/utils.d.ts +15 -0
  45. package/loader/cdn.js +3 -0
  46. package/loader/index.cjs.js +3 -0
  47. package/loader/index.d.ts +12 -0
  48. package/loader/index.es2017.js +3 -0
  49. package/loader/index.js +4 -0
  50. package/loader/package.json +10 -0
  51. package/package.json +2 -3
  52. package/LICENSE +0 -21
@@ -0,0 +1,136 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ const index = require('./index-c1f39e41.js');
6
+
7
+ const helperTabCss = ":host{display:block}.TabContent{font-size:14px;color:#000;font-weight:normal}";
8
+
9
+ const HelperTab = class {
10
+ constructor(hostRef) {
11
+ index.registerInstance(this, hostRef);
12
+ /**
13
+ * Selected index
14
+ */
15
+ this.selectedIndex = 0;
16
+ /**
17
+ * Client custom styling via string
18
+ */
19
+ this.clientStyling = '';
20
+ /**
21
+ * Client custom styling via url content
22
+ */
23
+ this.clientStylingUrlContent = '';
24
+ this.tabContent = '';
25
+ this.limitStylingAppends = false;
26
+ this.setClientStyling = () => {
27
+ let sheet = document.createElement('style');
28
+ sheet.innerHTML = this.clientStyling;
29
+ this.stylingContainer.prepend(sheet);
30
+ };
31
+ this.setClientStylingURL = () => {
32
+ let cssFile = document.createElement('style');
33
+ setTimeout(() => {
34
+ cssFile.innerHTML = this.clientStylingUrlContent;
35
+ this.stylingContainer.prepend(cssFile);
36
+ }, 1);
37
+ };
38
+ }
39
+ connectedCallback() {
40
+ /**
41
+ * fetch(cmsEndpoint + / + / + selectedIndex)
42
+ */
43
+ }
44
+ componentDidRender() {
45
+ // start custom styling area
46
+ if (!this.limitStylingAppends && this.stylingContainer) {
47
+ if (this.clientStyling)
48
+ this.setClientStyling();
49
+ if (this.clientStylingUrlContent)
50
+ this.setClientStylingURL();
51
+ this.limitStylingAppends = true;
52
+ }
53
+ // end custom styling area
54
+ }
55
+ render() {
56
+ this.tabContent = index.h("div", { class: "TabContent", ref: el => this.stylingContainer = el }, "Each play includes one set of numbers from 1 to 21 with a selectable number of 8 and a second, 4-digit set of numbers, with a minimum selection of 1. Draws are held every 5 minutes and the winnings are automatically credited to your account.");
57
+ if (this.selectedIndex + 1 == 2) {
58
+ this.tabContent = index.h("div", { class: "TabContent", ref: el => this.stylingContainer = el }, index.h("ol", null, index.h("li", null, "Register or Login"), index.h("li", null, "Buy tickets. Select 'Buy Tickets' to pick your numbers. Want us to automatically generate random numbers for you? Choose \u201CI feel lucky\u201D."), index.h("li", null, "Review and Complete your purchase. Once you've chosen your total number of plays, and confirmed your number of selections, review your ticket details and complete your purchase!")));
59
+ }
60
+ else if (this.selectedIndex + 1 == 3) {
61
+ this.tabContent = index.h("div", { class: "TabContent", ref: el => this.stylingContainer = el }, index.h("ul", null, index.h("li", null, "What are my odds of winning?"), index.h("li", null, "How can I find out if I\u2019ve won a draw game?"), index.h("li", null, "How do I claim my prize?")));
62
+ }
63
+ return (this.tabContent);
64
+ }
65
+ };
66
+ HelperTab.style = helperTabCss;
67
+
68
+ const helperTabsCss = "@import url(\"https://fonts.googleapis.com/css2?family=Roboto:wght@100&display=swap\");:host{display:block;font-family:\"Roboto\", sans-serif}.Tabs{display:flex;gap:10px;overflow-x:auto}.TabButton{cursor:pointer;width:auto;border-radius:4px;padding:8px 15px;margin:5px 0 10px;border:1px solid #009993;background:#FFF;color:#000;font-size:12px;transition:all 0.2s linear;text-align:center;letter-spacing:0;white-space:nowrap}.TabButton:hover{background:#F1F1F1}.TabButton.Active{background:#009993;color:#FFF}";
69
+
70
+ const HelperTabs = class {
71
+ constructor(hostRef) {
72
+ index.registerInstance(this, hostRef);
73
+ /**
74
+ * Tell me if it is disabled
75
+ */
76
+ this.disabled = false;
77
+ /**
78
+ * Tell me what tab is selected
79
+ */
80
+ this.selected = false;
81
+ /**
82
+ * Default selected index
83
+ */
84
+ this.selectedIndex = 0;
85
+ /**
86
+ * Tabs details
87
+ */
88
+ this.tabs = [{ label: 'How to Play' }, { label: 'About' }, { label: 'FAQs' }];
89
+ /**
90
+ * Client custom styling via string
91
+ */
92
+ this.clientStyling = '';
93
+ /**
94
+ * Client custom styling via url
95
+ */
96
+ this.clientStylingurl = '';
97
+ /**
98
+ * Client custom styling via url content
99
+ */
100
+ this.clientStylingUrlContent = '';
101
+ this.limitStylingAppends = false;
102
+ this.setClientStyling = () => {
103
+ let sheet = document.createElement('style');
104
+ sheet.innerHTML = this.clientStyling;
105
+ this.stylingContainer.prepend(sheet);
106
+ };
107
+ this.setClientStylingURL = () => {
108
+ let cssFile = document.createElement('style');
109
+ setTimeout(() => {
110
+ cssFile.innerHTML = this.clientStylingUrlContent;
111
+ this.stylingContainer.prepend(cssFile);
112
+ }, 1);
113
+ };
114
+ }
115
+ connectedCallback() {
116
+ }
117
+ componentDidRender() {
118
+ // start custom styling area
119
+ if (!this.limitStylingAppends && this.stylingContainer) {
120
+ this.setClientStyling();
121
+ if (this.clientStylingUrlContent) {
122
+ this.setClientStylingURL();
123
+ }
124
+ this.limitStylingAppends = true;
125
+ }
126
+ // end custom styling area
127
+ }
128
+ render() {
129
+ return (index.h("div", { ref: el => this.stylingContainer = el }, index.h("div", { class: "Tabs" }, this.tabs.map((tab, index$1) => index.h("button", { class: 'TabButton' + (this.selectedIndex == index$1 ? ' Active' : ''), onClick: () => this.selectedIndex = index$1 }, tab.label))), index.h("div", null, index.h("helper-tab", { selectedIndex: this.selectedIndex, "client-styling": this.clientStyling, "client-stylingurl": this.clientStylingurl, "client-styling-url-content": this.clientStylingUrlContent }))));
130
+ }
131
+ get host() { return index.getElement(this); }
132
+ };
133
+ HelperTabs.style = helperTabsCss;
134
+
135
+ exports.helper_tab = HelperTab;
136
+ exports.helper_tabs = HelperTabs;
@@ -0,0 +1,19 @@
1
+ 'use strict';
2
+
3
+ const index = require('./index-c1f39e41.js');
4
+
5
+ /*
6
+ Stencil Client Patch Browser v2.15.2 | MIT Licensed | https://stenciljs.com
7
+ */
8
+ const patchBrowser = () => {
9
+ const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('helper-tabs.cjs.js', document.baseURI).href));
10
+ const opts = {};
11
+ if (importMeta !== '') {
12
+ opts.resourcesUrl = new URL('.', importMeta).href;
13
+ }
14
+ return index.promiseResolve(opts);
15
+ };
16
+
17
+ patchBrowser().then(options => {
18
+ return index.bootstrapLazy([["helper-tab_2.cjs",[[1,"helper-tabs",{"disabled":[516],"label":[513],"selected":[516],"cmsEndpoint":[513,"cms-endpoint"],"selectedIndex":[1538,"selected-index"],"tabs":[16],"clientStyling":[513,"client-styling"],"clientStylingurl":[513,"client-stylingurl"],"clientStylingUrlContent":[513,"client-styling-url-content"],"limitStylingAppends":[32]}],[1,"helper-tab",{"selectedIndex":[514,"selected-index"],"cmsEndpoint":[513,"cms-endpoint"],"clientStyling":[513,"client-styling"],"clientStylingUrlContent":[513,"client-styling-url-content"],"tabContent":[32],"limitStylingAppends":[32]}]]]], options);
19
+ });