smoothly 0.1.113 → 0.1.116

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 (251) hide show
  1. package/dist/cjs/{Notice-9c2b52b7.js → Notice-839702d8.js} +34 -26
  2. package/dist/cjs/{Trigger-74bd1ee8.js → Trigger-cf376531.js} +55 -146
  3. package/dist/cjs/{index-41a36ce2.js → index-1c61bdd3.js} +27 -1
  4. package/dist/cjs/index.cjs.js +20 -8
  5. package/dist/cjs/loader.cjs.js +3 -19
  6. package/dist/cjs/{smoothly-accordion_50.cjs.entry.js → smoothly-accordion_51.cjs.entry.js} +7698 -1491
  7. package/dist/cjs/smoothly-google-font.cjs.entry.js +2 -2
  8. package/dist/cjs/smoothly-radio-group.cjs.entry.js +2 -2
  9. package/dist/cjs/smoothly-reorder.cjs.entry.js +2 -2
  10. package/dist/cjs/smoothly-trigger-sink.cjs.entry.js +5 -5
  11. package/dist/cjs/smoothly-trigger-source.cjs.entry.js +5 -5
  12. package/dist/cjs/smoothly.cjs.js +5 -113
  13. package/dist/collection/collection-manifest.json +3 -2
  14. package/dist/collection/components/app/style.css +6 -7
  15. package/dist/collection/components/app-demo/index.js +6 -1
  16. package/dist/collection/components/button/index.js +168 -0
  17. package/dist/collection/components/button/style.css +49 -0
  18. package/dist/collection/components/menu-options/style.css +2 -2
  19. package/dist/collection/components/picker/index.js +10 -6
  20. package/dist/collection/components/picker/style.css +14 -14
  21. package/dist/collection/components/selector/style.css +3 -3
  22. package/dist/collection/components/tab/style.css +3 -3
  23. package/dist/collection/components/table/header/style.css +5 -5
  24. package/dist/collection/components/trigger/style.css +3 -3
  25. package/dist/custom-elements/index.d.ts +6 -0
  26. package/dist/custom-elements/index.js +7785 -2974
  27. package/dist/esm/{Notice-4131b4e0.js → Notice-608b552c.js} +34 -26
  28. package/dist/esm/{Trigger-d7b181ec.js → Trigger-365408f0.js} +55 -146
  29. package/dist/esm/{index-dcb2b612.js → index-a3737440.js} +27 -1
  30. package/dist/esm/index.js +17 -4
  31. package/dist/esm/loader.js +3 -19
  32. package/dist/esm/polyfills/css-shim.js +1 -1
  33. package/dist/esm/{smoothly-accordion_50.entry.js → smoothly-accordion_51.entry.js} +7698 -1492
  34. package/dist/esm/smoothly-google-font.entry.js +2 -2
  35. package/dist/esm/smoothly-radio-group.entry.js +2 -2
  36. package/dist/esm/smoothly-reorder.entry.js +2 -2
  37. package/dist/esm/smoothly-trigger-sink.entry.js +3 -3
  38. package/dist/esm/smoothly-trigger-source.entry.js +3 -3
  39. package/dist/esm/smoothly.js +5 -113
  40. package/dist/smoothly/index.esm.js +1 -376
  41. package/dist/smoothly/p-0215b4da.entry.js +1 -0
  42. package/dist/smoothly/{p-074a0448.js → p-0cba3e3d.js} +1 -1
  43. package/dist/smoothly/p-4fa231df.entry.js +1 -0
  44. package/dist/smoothly/p-6ca0d36c.js +1 -0
  45. package/dist/smoothly/p-6f009ac9.entry.js +1 -0
  46. package/dist/smoothly/p-7a30d9b8.js +1 -0
  47. package/dist/smoothly/p-8ae38136.entry.js +1 -0
  48. package/dist/smoothly/p-993534fa.entry.js +1 -0
  49. package/dist/smoothly/p-eec1c703.entry.js +1 -0
  50. package/dist/smoothly/smoothly.esm.js +1 -125
  51. package/dist/types/components/button/index.d.ts +11 -0
  52. package/dist/types/components.d.ts +27 -0
  53. package/dist/types/stencil-public-runtime.d.ts +6 -4
  54. package/package.json +18 -18
  55. package/dist/cjs/App-339acc9b.js +0 -647
  56. package/dist/cjs/_commonjsHelpers-10109b76.js +0 -48
  57. package/dist/cjs/app-globals-3a1e7e63.js +0 -5
  58. package/dist/cjs/css-shim-88cc6900.js +0 -6
  59. package/dist/cjs/dom-95afd968.js +0 -75
  60. package/dist/cjs/generate-f9a36f25.js +0 -66
  61. package/dist/cjs/index-138c41c2.js +0 -3066
  62. package/dist/cjs/index-40d009d5.js +0 -1354
  63. package/dist/cjs/index-ac32385c.js +0 -18850
  64. package/dist/cjs/index-d66869d7.js +0 -1672
  65. package/dist/cjs/shadow-css-71d0f821.js +0 -391
  66. package/dist/cjs/smoothly-accordion-item.cjs.entry.js +0 -54
  67. package/dist/cjs/smoothly-accordion.cjs.entry.js +0 -55
  68. package/dist/cjs/smoothly-app-demo.cjs.entry.js +0 -29
  69. package/dist/cjs/smoothly-app.cjs.entry.js +0 -19
  70. package/dist/cjs/smoothly-backtotop.cjs.entry.js +0 -37
  71. package/dist/cjs/smoothly-calendar.cjs.entry.js +0 -95
  72. package/dist/cjs/smoothly-checkbox.cjs.entry.js +0 -18671
  73. package/dist/cjs/smoothly-dialog-demo.cjs.entry.js +0 -16
  74. package/dist/cjs/smoothly-dialog.cjs.entry.js +0 -38
  75. package/dist/cjs/smoothly-display-amount.cjs.entry.js +0 -59
  76. package/dist/cjs/smoothly-display-date-time.cjs.entry.js +0 -20
  77. package/dist/cjs/smoothly-display-demo.cjs.entry.js +0 -25
  78. package/dist/cjs/smoothly-display.cjs.entry.js +0 -41
  79. package/dist/cjs/smoothly-frame.cjs.entry.js +0 -50
  80. package/dist/cjs/smoothly-icon-demo.cjs.entry.js +0 -491
  81. package/dist/cjs/smoothly-icon.cjs.entry.js +0 -52
  82. package/dist/cjs/smoothly-input-date-range.cjs.entry.js +0 -50
  83. package/dist/cjs/smoothly-input-date.cjs.entry.js +0 -44
  84. package/dist/cjs/smoothly-input-demo.cjs.entry.js +0 -19
  85. package/dist/cjs/smoothly-input-month.cjs.entry.js +0 -41
  86. package/dist/cjs/smoothly-input.cjs.entry.js +0 -202
  87. package/dist/cjs/smoothly-item.cjs.entry.js +0 -43
  88. package/dist/cjs/smoothly-menu-options.cjs.entry.js +0 -108
  89. package/dist/cjs/smoothly-notification.cjs.entry.js +0 -67
  90. package/dist/cjs/smoothly-notifier.cjs.entry.js +0 -29
  91. package/dist/cjs/smoothly-option.cjs.entry.js +0 -33
  92. package/dist/cjs/smoothly-picker.cjs.entry.js +0 -151
  93. package/dist/cjs/smoothly-popup.cjs.entry.js +0 -38
  94. package/dist/cjs/smoothly-quiet.cjs.entry.js +0 -19
  95. package/dist/cjs/smoothly-radio.cjs.entry.js +0 -28
  96. package/dist/cjs/smoothly-room.cjs.entry.js +0 -16
  97. package/dist/cjs/smoothly-select-demo.cjs.entry.js +0 -86
  98. package/dist/cjs/smoothly-select.cjs.entry.js +0 -31
  99. package/dist/cjs/smoothly-selector.cjs.entry.js +0 -119
  100. package/dist/cjs/smoothly-skeleton.cjs.entry.js +0 -27
  101. package/dist/cjs/smoothly-spinner.cjs.entry.js +0 -24
  102. package/dist/cjs/smoothly-submit.cjs.entry.js +0 -60
  103. package/dist/cjs/smoothly-svg.cjs.entry.js +0 -41
  104. package/dist/cjs/smoothly-tab-switch.cjs.entry.js +0 -32
  105. package/dist/cjs/smoothly-tab.cjs.entry.js +0 -37
  106. package/dist/cjs/smoothly-table-cell.cjs.entry.js +0 -19
  107. package/dist/cjs/smoothly-table-demo.cjs.entry.js +0 -22
  108. package/dist/cjs/smoothly-table-expandable-cell.cjs.entry.js +0 -45
  109. package/dist/cjs/smoothly-table-expandable-row.cjs.entry.js +0 -32
  110. package/dist/cjs/smoothly-table-header.cjs.entry.js +0 -41
  111. package/dist/cjs/smoothly-table-row.cjs.entry.js +0 -38
  112. package/dist/cjs/smoothly-table.cjs.entry.js +0 -26
  113. package/dist/cjs/smoothly-trigger.cjs.entry.js +0 -36
  114. package/dist/cjs/smoothly-tuple.cjs.entry.js +0 -16
  115. package/dist/cjs/smoothly-urlencoded.cjs.entry.js +0 -19
  116. package/dist/esm/App-22187759.js +0 -645
  117. package/dist/esm/_commonjsHelpers-8fe71198.js +0 -44
  118. package/dist/esm/app-globals-0f993ce5.js +0 -3
  119. package/dist/esm/css-shim-c64026cd.js +0 -4
  120. package/dist/esm/dom-a712b575.js +0 -73
  121. package/dist/esm/generate-50b98474.js +0 -61
  122. package/dist/esm/index-02a70ac1.js +0 -3027
  123. package/dist/esm/index-401c6ce3.js +0 -1670
  124. package/dist/esm/index-a5a08f46.js +0 -18848
  125. package/dist/esm/index-c8b5d468.js +0 -1349
  126. package/dist/esm/shadow-css-1e16431b.js +0 -389
  127. package/dist/esm/smoothly-accordion-item.entry.js +0 -50
  128. package/dist/esm/smoothly-accordion.entry.js +0 -51
  129. package/dist/esm/smoothly-app-demo.entry.js +0 -25
  130. package/dist/esm/smoothly-app.entry.js +0 -15
  131. package/dist/esm/smoothly-backtotop.entry.js +0 -33
  132. package/dist/esm/smoothly-calendar.entry.js +0 -91
  133. package/dist/esm/smoothly-checkbox.entry.js +0 -18667
  134. package/dist/esm/smoothly-dialog-demo.entry.js +0 -12
  135. package/dist/esm/smoothly-dialog.entry.js +0 -34
  136. package/dist/esm/smoothly-display-amount.entry.js +0 -55
  137. package/dist/esm/smoothly-display-date-time.entry.js +0 -16
  138. package/dist/esm/smoothly-display-demo.entry.js +0 -21
  139. package/dist/esm/smoothly-display.entry.js +0 -37
  140. package/dist/esm/smoothly-frame.entry.js +0 -46
  141. package/dist/esm/smoothly-icon-demo.entry.js +0 -487
  142. package/dist/esm/smoothly-icon.entry.js +0 -48
  143. package/dist/esm/smoothly-input-date-range.entry.js +0 -46
  144. package/dist/esm/smoothly-input-date.entry.js +0 -40
  145. package/dist/esm/smoothly-input-demo.entry.js +0 -15
  146. package/dist/esm/smoothly-input-month.entry.js +0 -37
  147. package/dist/esm/smoothly-input.entry.js +0 -198
  148. package/dist/esm/smoothly-item.entry.js +0 -39
  149. package/dist/esm/smoothly-menu-options.entry.js +0 -104
  150. package/dist/esm/smoothly-notification.entry.js +0 -63
  151. package/dist/esm/smoothly-notifier.entry.js +0 -25
  152. package/dist/esm/smoothly-option.entry.js +0 -29
  153. package/dist/esm/smoothly-picker.entry.js +0 -147
  154. package/dist/esm/smoothly-popup.entry.js +0 -34
  155. package/dist/esm/smoothly-quiet.entry.js +0 -15
  156. package/dist/esm/smoothly-radio.entry.js +0 -24
  157. package/dist/esm/smoothly-room.entry.js +0 -12
  158. package/dist/esm/smoothly-select-demo.entry.js +0 -82
  159. package/dist/esm/smoothly-select.entry.js +0 -27
  160. package/dist/esm/smoothly-selector.entry.js +0 -115
  161. package/dist/esm/smoothly-skeleton.entry.js +0 -23
  162. package/dist/esm/smoothly-spinner.entry.js +0 -20
  163. package/dist/esm/smoothly-submit.entry.js +0 -56
  164. package/dist/esm/smoothly-svg.entry.js +0 -37
  165. package/dist/esm/smoothly-tab-switch.entry.js +0 -28
  166. package/dist/esm/smoothly-tab.entry.js +0 -33
  167. package/dist/esm/smoothly-table-cell.entry.js +0 -15
  168. package/dist/esm/smoothly-table-demo.entry.js +0 -18
  169. package/dist/esm/smoothly-table-expandable-cell.entry.js +0 -41
  170. package/dist/esm/smoothly-table-expandable-row.entry.js +0 -28
  171. package/dist/esm/smoothly-table-header.entry.js +0 -37
  172. package/dist/esm/smoothly-table-row.entry.js +0 -34
  173. package/dist/esm/smoothly-table.entry.js +0 -22
  174. package/dist/esm/smoothly-trigger.entry.js +0 -32
  175. package/dist/esm/smoothly-tuple.entry.js +0 -12
  176. package/dist/esm/smoothly-urlencoded.entry.js +0 -15
  177. package/dist/smoothly/App-22187759.js +0 -645
  178. package/dist/smoothly/GoogleFont-8474516b.js +0 -21
  179. package/dist/smoothly/_commonjsHelpers-8fe71198.js +0 -44
  180. package/dist/smoothly/app-globals-0f993ce5.js +0 -3
  181. package/dist/smoothly/css-shim-c64026cd.js +0 -4
  182. package/dist/smoothly/dom-a712b575.js +0 -73
  183. package/dist/smoothly/generate-50b98474.js +0 -61
  184. package/dist/smoothly/index-02a70ac1.js +0 -3027
  185. package/dist/smoothly/index-401c6ce3.js +0 -1670
  186. package/dist/smoothly/index-a5a08f46.js +0 -18848
  187. package/dist/smoothly/index-c8b5d468.js +0 -1349
  188. package/dist/smoothly/p-06aab261.entry.js +0 -1
  189. package/dist/smoothly/p-0c1e9588.entry.js +0 -1
  190. package/dist/smoothly/p-14232157.entry.js +0 -1
  191. package/dist/smoothly/p-19518931.js +0 -1
  192. package/dist/smoothly/p-22d4d5a7.entry.js +0 -1
  193. package/dist/smoothly/p-2cda1784.js +0 -1
  194. package/dist/smoothly/p-9fa3ab06.entry.js +0 -1
  195. package/dist/smoothly/p-b8a3e273.entry.js +0 -1
  196. package/dist/smoothly/shadow-css-1e16431b.js +0 -389
  197. package/dist/smoothly/smoothly-accordion-item.entry.js +0 -50
  198. package/dist/smoothly/smoothly-accordion.entry.js +0 -51
  199. package/dist/smoothly/smoothly-app-demo.entry.js +0 -25
  200. package/dist/smoothly/smoothly-app.entry.js +0 -15
  201. package/dist/smoothly/smoothly-backtotop.entry.js +0 -33
  202. package/dist/smoothly/smoothly-calendar.entry.js +0 -91
  203. package/dist/smoothly/smoothly-checkbox.entry.js +0 -18667
  204. package/dist/smoothly/smoothly-dialog-demo.entry.js +0 -12
  205. package/dist/smoothly/smoothly-dialog.entry.js +0 -34
  206. package/dist/smoothly/smoothly-display-amount.entry.js +0 -55
  207. package/dist/smoothly/smoothly-display-date-time.entry.js +0 -16
  208. package/dist/smoothly/smoothly-display-demo.entry.js +0 -21
  209. package/dist/smoothly/smoothly-display.entry.js +0 -37
  210. package/dist/smoothly/smoothly-frame.entry.js +0 -46
  211. package/dist/smoothly/smoothly-google-font.entry.js +0 -13
  212. package/dist/smoothly/smoothly-icon-demo.entry.js +0 -487
  213. package/dist/smoothly/smoothly-icon.entry.js +0 -48
  214. package/dist/smoothly/smoothly-input-date-range.entry.js +0 -46
  215. package/dist/smoothly/smoothly-input-date.entry.js +0 -40
  216. package/dist/smoothly/smoothly-input-demo.entry.js +0 -15
  217. package/dist/smoothly/smoothly-input-month.entry.js +0 -37
  218. package/dist/smoothly/smoothly-input.entry.js +0 -198
  219. package/dist/smoothly/smoothly-item.entry.js +0 -39
  220. package/dist/smoothly/smoothly-menu-options.entry.js +0 -104
  221. package/dist/smoothly/smoothly-notification.entry.js +0 -63
  222. package/dist/smoothly/smoothly-notifier.entry.js +0 -25
  223. package/dist/smoothly/smoothly-option.entry.js +0 -29
  224. package/dist/smoothly/smoothly-picker.entry.js +0 -147
  225. package/dist/smoothly/smoothly-popup.entry.js +0 -34
  226. package/dist/smoothly/smoothly-quiet.entry.js +0 -15
  227. package/dist/smoothly/smoothly-radio-group.entry.js +0 -16
  228. package/dist/smoothly/smoothly-radio.entry.js +0 -24
  229. package/dist/smoothly/smoothly-reorder.entry.js +0 -99
  230. package/dist/smoothly/smoothly-room.entry.js +0 -12
  231. package/dist/smoothly/smoothly-select-demo.entry.js +0 -82
  232. package/dist/smoothly/smoothly-select.entry.js +0 -27
  233. package/dist/smoothly/smoothly-selector.entry.js +0 -115
  234. package/dist/smoothly/smoothly-skeleton.entry.js +0 -23
  235. package/dist/smoothly/smoothly-spinner.entry.js +0 -20
  236. package/dist/smoothly/smoothly-submit.entry.js +0 -56
  237. package/dist/smoothly/smoothly-svg.entry.js +0 -37
  238. package/dist/smoothly/smoothly-tab-switch.entry.js +0 -28
  239. package/dist/smoothly/smoothly-tab.entry.js +0 -33
  240. package/dist/smoothly/smoothly-table-cell.entry.js +0 -15
  241. package/dist/smoothly/smoothly-table-demo.entry.js +0 -18
  242. package/dist/smoothly/smoothly-table-expandable-cell.entry.js +0 -41
  243. package/dist/smoothly/smoothly-table-expandable-row.entry.js +0 -28
  244. package/dist/smoothly/smoothly-table-header.entry.js +0 -37
  245. package/dist/smoothly/smoothly-table-row.entry.js +0 -34
  246. package/dist/smoothly/smoothly-table.entry.js +0 -22
  247. package/dist/smoothly/smoothly-trigger-sink.entry.js +0 -29
  248. package/dist/smoothly/smoothly-trigger-source.entry.js +0 -28
  249. package/dist/smoothly/smoothly-trigger.entry.js +0 -32
  250. package/dist/smoothly/smoothly-tuple.entry.js +0 -12
  251. package/dist/smoothly/smoothly-urlencoded.entry.js +0 -15
@@ -1,12 +0,0 @@
1
- import { r as registerInstance, h } from './index-02a70ac1.js';
2
-
3
- let SmoothlyDialogDemo = class {
4
- constructor(hostRef) {
5
- registerInstance(this, hostRef);
6
- }
7
- render() {
8
- return (h("smoothly-dialog", { color: "default", style: { "margin-top": "6vh" }, closable: true }, h("smoothly-frame", { url: "https://www.wikipedia.org/", name: "parent", style: { height: "80vh" } })));
9
- }
10
- };
11
-
12
- export { SmoothlyDialogDemo as smoothly_dialog_demo };
@@ -1,34 +0,0 @@
1
- import { r as registerInstance, h, k as Host } from './index-02a70ac1.js';
2
- import { T as Trigger } from './index-c8b5d468.js';
3
- import './GoogleFont-8474516b.js';
4
-
5
- const styleCss = ".sc-smoothly-dialog-h{display:block;position:fixed;left:0;top:0;width:100%;height:100%;z-index:1;background:rgba(var(--smoothly-default-color), var(--smoothly-semitransparent)) !important}[hidden].sc-smoothly-dialog-h{display:none}.sc-smoothly-dialog-h>header.sc-smoothly-dialog{border-top-left-radius:8px;border-top-right-radius:8px;margin-top:2em;color:rgb(var(--smoothly-primary-contrast));background:rgb(var(--smoothly-primary-color));border-color:rgb(var(--smoothly-primary-color))}.sc-smoothly-dialog-h:not([header]) header.sc-smoothly-dialog{border:none}.sc-smoothly-dialog-h>*.sc-smoothly-dialog{position:relative;color:rgb(var(--smoothly-default-contrast));background-color:rgb(var(--smoothly-default-color));border-color:rgb(var(--smoothly-color));border-width:1px;border-style:solid;max-width:40em;width:calc(100vw - 4em - 2px);max-height:calc(100vh - 6em - 2px);height:auto;margin-left:auto;margin-right:auto;border-collapse:collapse}.sc-smoothly-dialog-h>main.sc-smoothly-dialog{border-bottom-left-radius:8px;border-bottom-right-radius:8px;margin-bottom:2em;border:1px solid rgb(var(--smoothly-default-contrast));box-sizing:border-box;overflow:hidden}.sc-smoothly-dialog-h:not([header]) main.sc-smoothly-dialog{border-radius:8px}.sc-smoothly-dialog-h>*.sc-smoothly-dialog>smoothly-trigger.sc-smoothly-dialog{position:absolute;right:-2em;top:-2em;z-index:1;border-color:transparent}.sc-smoothly-dialog-h>*.sc-smoothly-dialog>smoothly-trigger.sc-smoothly-dialog:hover{border-color:transparent}.sc-smoothly-dialog-h smoothly-icon.sc-smoothly-dialog{background-color:rgb(var(--smoothly-color));border-radius:50%}.sc-smoothly-dialog-h>*.sc-smoothly-dialog>*.sc-smoothly-dialog{margin:10px}";
6
-
7
- let SmoothlyDialog = class {
8
- constructor(hostRef) {
9
- registerInstance(this, hostRef);
10
- this.open = true;
11
- this.closable = false;
12
- }
13
- TriggerListener(event) {
14
- if (Trigger.is(event.detail) && event.detail.name == "close")
15
- this.open = false;
16
- }
17
- hostData() {
18
- return {
19
- style: {
20
- display: this.open ? "block" : "none",
21
- },
22
- };
23
- }
24
- __stencil_render() {
25
- return [
26
- h("header", null, this.closable ? (h("smoothly-trigger", { fill: "clear", name: "close" }, h("smoothly-icon", { name: "close-circle", fill: "solid", color: this.color }))) : ([]), this.header ? h("h1", null, this.header) : h("slot", { name: "header" })),
27
- h("main", null, h("slot", null)),
28
- ];
29
- }
30
- render() { return h(Host, this.hostData(), this.__stencil_render()); }
31
- };
32
- SmoothlyDialog.style = styleCss;
33
-
34
- export { SmoothlyDialog as smoothly_dialog };
@@ -1,55 +0,0 @@
1
- import { r as registerInstance } from './index-02a70ac1.js';
2
- import { d as dist } from './index-a5a08f46.js';
3
- import './_commonjsHelpers-8fe71198.js';
4
-
5
- const styleCss = ".sc-smoothly-display-amount-h{display:block}[hidden].sc-smoothly-display-amount-h{display:none}";
6
-
7
- let SmoothlyDisplayAmount = class {
8
- constructor(hostRef) {
9
- registerInstance(this, hostRef);
10
- }
11
- format(amount) {
12
- const digitsPerGroup = 3;
13
- const defaultDecimals = 2;
14
- const maxDecimals = (dist.Currency.decimalDigits(this.currency) ? dist.Currency.decimalDigits(this.currency) : defaultDecimals);
15
- let beforeSeparator = amount.length;
16
- let separator;
17
- let result = amount;
18
- if (result == "")
19
- result = "0";
20
- if (amount.includes(".")) {
21
- separator = amount.indexOf(".");
22
- if (separator == 0) {
23
- result = "0" + result;
24
- separator++;
25
- }
26
- beforeSeparator = separator;
27
- result = result.padEnd(separator + maxDecimals + 1, "0");
28
- result = result.substring(0, separator + maxDecimals + 1);
29
- }
30
- else {
31
- result = result + ".";
32
- separator = result.length - 1;
33
- result = result.padEnd(separator + maxDecimals + 1, "0");
34
- }
35
- const spaces = Math.ceil(beforeSeparator / digitsPerGroup) - 1;
36
- if (spaces > 0) {
37
- for (let i = 0; i < spaces; i++) {
38
- const position = beforeSeparator - (spaces - i) * digitsPerGroup;
39
- result = result.slice(0, position) + " " + result.slice(position, result.length);
40
- beforeSeparator++;
41
- }
42
- }
43
- return result;
44
- }
45
- render() {
46
- return [
47
- typeof this.amount == "number" ? this.format(this.amount.toString()) : this.format(this.amount),
48
- " ",
49
- this.currency,
50
- ];
51
- }
52
- };
53
- SmoothlyDisplayAmount.style = styleCss;
54
-
55
- export { SmoothlyDisplayAmount as smoothly_display_amount };
@@ -1,16 +0,0 @@
1
- import { r as registerInstance } from './index-02a70ac1.js';
2
-
3
- const styleCss = ".sc-smoothly-display-date-time-h{display:block}[hidden].sc-smoothly-display-date-time-h{display:none}";
4
-
5
- let SmoothlyDisplayDateTime = class {
6
- constructor(hostRef) {
7
- registerInstance(this, hostRef);
8
- }
9
- render() {
10
- const datetime = this.datetime.split("T");
11
- return [datetime[0], " ", datetime[1]];
12
- }
13
- };
14
- SmoothlyDisplayDateTime.style = styleCss;
15
-
16
- export { SmoothlyDisplayDateTime as smoothly_display_date_time };
@@ -1,21 +0,0 @@
1
- import { r as registerInstance, i as createEvent, h } from './index-02a70ac1.js';
2
- import { N as Notice } from './index-c8b5d468.js';
3
- import './GoogleFont-8474516b.js';
4
-
5
- let SmoothlyDisplayDemo = class {
6
- constructor(hostRef) {
7
- registerInstance(this, hostRef);
8
- this.notice = createEvent(this, "notice", 7);
9
- }
10
- noticeWarning(notice) {
11
- console.log("emit", notice);
12
- this.notice.emit(notice);
13
- }
14
- render() {
15
- return [
16
- h("main", null, h("smoothly-popup", null, h("div", null, "Popup, click me"), h("div", { color: "dark", slot: "popup" }, "1 line popup")), h("smoothly-display-date-time", { datetime: "2019-08-15T08:08:17.65Z" }), h("dl", null, h("dt", null, "text"), h("dd", null, h("smoothly-display", { type: "text", value: "text" })), h("dt", null, "postal code"), h("dd", null, h("smoothly-display", { type: "postal-code", value: "752 31" })), h("dt", null, "password"), h("dd", null, h("smoothly-display", { type: "password", value: "password" })), h("dt", null, "email"), h("dd", null, h("smoothly-display", { type: "email", value: "test@example.com" })), h("dt", null, "price"), h("dd", null, h("smoothly-display", { type: "price", value: "13.37", currency: "SEK" })), h("dt", null, "percent"), h("dd", null, h("smoothly-display", { type: "percent", value: "42" })), h("dt", null, "phone"), h("dd", null, h("smoothly-display", { type: "phone", value: "0101881108" })), h("dt", null, "card number"), h("dd", null, h("smoothly-display", { type: "card-number", value: "4111111111111111" })), h("dt", null, "card expires"), h("dd", null, h("smoothly-display", { type: "card-expires", value: "7/22" })), h("dt", null, "card csc"), h("dd", null, h("smoothly-display", { type: "card-csc", value: "987" })), h("dt", null, "Quiet"), h("dd", null, h("smoothly-quiet", { color: "dark" }, "-"))), h("smoothly-skeleton", { period: 3, distance: "20rem", width: "20rem" }), h("smoothly-skeleton", { period: 3, distance: "20rem", color: "200,200,255" }), h("smoothly-skeleton", { period: 3, distance: "20rem", color: "var(--smoothly-warning-color)" }), h("smoothly-skeleton", { period: 3, distance: "20rem" }), h("smoothly-skeleton", { align: "center", period: 3, distance: "20rem", width: "20rem" }), h("smoothly-skeleton", { align: "center", period: 3, distance: "20rem" }), h("smoothly-skeleton", { align: "center", period: 3, distance: "20rem" }), h("smoothly-skeleton", { align: "center", period: 3, distance: "20rem" }), h("smoothly-skeleton", { align: "right", period: 3, distance: "20rem", width: "20rem" }), h("smoothly-skeleton", { align: "right", period: 3, distance: "20rem" }), h("smoothly-skeleton", { align: "right", period: 3, distance: "20rem" }), h("smoothly-skeleton", { align: "right", period: 3, distance: "20rem" }), h("smoothly-urlencoded", { data: "hej=hopp&tjena=moss" }), h("div", { style: { display: "flex", justifyContent: "space-between" } }, h("smoothly-popup", { direction: "down" }, "Click for popup", h("span", { slot: "popup", color: "dark", style: { whiteSpace: "nowrap" } }, "Some popup stuff that has a lot of text")), h("smoothly-popup", { direction: "down" }, "Click for popup", h("span", { slot: "popup", color: "dark", style: { whiteSpace: "nowrap" } }, "Some popup with a bunch of text."))), h("p", null, "Test of diffrent kinds of notifier:"), h("button", { onClick: () => this.noticeWarning(Notice.warn("This is a test warning notice.")) }, "warning"), h("button", { onClick: () => this.noticeWarning(Notice.succeded("This is a test success notice.")) }, "success"), h("button", { onClick: () => this.noticeWarning(Notice.failed("This is a test danger notice.")) }, "danger"), h("button", { onClick: () => this.noticeWarning(Notice.execute("This is a test execute notice.", () => new Promise(resolve => window.setTimeout(() => resolve([true, "This went great"]), 3000)))) }, "execute"), h("button", { onClick: () => this.noticeWarning(Notice.delay("This is a test delay notice.", () => new Promise(resolve => window.setTimeout(() => resolve([true, "This went great"]), 3000)))) }, "delay"), h("div", { style: { position: "relative", height: "10em" } }, "Large Spinner", h("smoothly-spinner", { active: true, size: "large", style: { "--background-color": "255,255,255", "--background-opacity": "0.2", "--spinner-color": "0,130,0", } })), h("div", { style: { position: "relative", height: "10em" } }, "Medium Spinner", h("smoothly-spinner", { active: true, size: "medium" })), h("div", { style: { position: "relative", height: "10em" } }, "Small Spinner", h("smoothly-spinner", { active: true, size: "small" })), h("div", { style: { position: "absolute", left: "500px", top: "150px" } }, h("smoothly-svg", { url: "https://theme.payfunc.com/intergiro/animated-logo.svg" }))),
17
- ];
18
- }
19
- };
20
-
21
- export { SmoothlyDisplayDemo as smoothly_display_demo };
@@ -1,37 +0,0 @@
1
- import { r as registerInstance, h } from './index-02a70ac1.js';
2
- import { d as dist } from './index-401c6ce3.js';
3
- import './_commonjsHelpers-8fe71198.js';
4
- import './index-a5a08f46.js';
5
-
6
- const styleCss = ".sc-smoothly-display-h{display:block}[hidden].sc-smoothly-display-h{display:none}";
7
-
8
- let SmoothlyDisplay = class {
9
- constructor(hostRef) {
10
- registerInstance(this, hostRef);
11
- }
12
- render() {
13
- let result;
14
- const type = this.type;
15
- switch (type) {
16
- default:
17
- result = dist.format(this.value, type);
18
- break;
19
- case "email":
20
- result = h("a", { href: "mailto:" + this.value }, dist.format(this.value, type));
21
- break;
22
- case "phone":
23
- result = h("a", { href: "tel:" + this.value }, dist.format(this.value, type, this.country));
24
- break;
25
- case "postal-code":
26
- result = dist.format(this.value, type, this.country);
27
- break;
28
- case "price":
29
- result = dist.format(this.value, type, this.currency);
30
- break;
31
- }
32
- return result;
33
- }
34
- };
35
- SmoothlyDisplay.style = styleCss;
36
-
37
- export { SmoothlyDisplay as smoothly_display };
@@ -1,46 +0,0 @@
1
- import { r as registerInstance, i as createEvent, h, j as getElement } from './index-02a70ac1.js';
2
- import { M as Message, T as Trigger } from './index-c8b5d468.js';
3
- import './GoogleFont-8474516b.js';
4
-
5
- const styleCss = ".sc-smoothly-frame-h{display:block;width:100%;height:100%}[hidden].sc-smoothly-frame-h{display:none}.sc-smoothly-frame-h>iframe.sc-smoothly-frame{border:none;padding:none;margin:none}";
6
-
7
- let SmoothlyFrame = class {
8
- constructor(hostRef) {
9
- registerInstance(this, hostRef);
10
- this.trigger = createEvent(this, "trigger", 7);
11
- this.message = createEvent(this, "message", 7);
12
- }
13
- get contentWindow() {
14
- const iframe = this.element && this.element.firstElementChild ? this.element.firstElementChild : undefined;
15
- return (iframe && iframe.contentWindow) || undefined;
16
- }
17
- get defaultOrigin() {
18
- const match = this.url.match(/^(([a-z]+\+)*[a-z]+:\/\/)?[^/^\n]+/);
19
- return match ? match[0] : "*";
20
- }
21
- componentDidLoad() {
22
- var _a;
23
- if (this.contentWindow)
24
- Message.listen((_a = this.origin) !== null && _a !== void 0 ? _a : this.defaultOrigin, (destination, content) => {
25
- if (destination == this.name)
26
- if (Trigger.is(content))
27
- this.trigger.emit(content);
28
- else
29
- this.message.emit({ destination, content });
30
- }, window);
31
- }
32
- async send(message, content) {
33
- var _a, _b;
34
- if (typeof message == "string")
35
- Message.send(((_a = this.origin) !== null && _a !== void 0 ? _a : this.defaultOrigin) + "#" + message, content, this.contentWindow);
36
- else if (Message.is(message) && this.contentWindow)
37
- Message.send({ destination: ((_b = this.origin) !== null && _b !== void 0 ? _b : this.defaultOrigin) + "#" + message.destination, content: message.destination }, this.contentWindow);
38
- }
39
- render() {
40
- return h("iframe", { src: this.url + "#" + window.location.origin, height: "100%", width: "100%" });
41
- }
42
- get element() { return getElement(this); }
43
- };
44
- SmoothlyFrame.style = styleCss;
45
-
46
- export { SmoothlyFrame as smoothly_frame };