@ganpatiinfo/gids-web-dom-reference 3.1.0 → 4.0.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 (110) hide show
  1. package/CHANGELOG.md +52 -0
  2. package/dist/components/GidsDismissButton/GidsDismissButton.d.ts +8 -0
  3. package/dist/components/GidsDismissButton/GidsDismissButton.d.ts.map +1 -0
  4. package/dist/components/GidsDismissButton/GidsDismissButton.js +20 -0
  5. package/dist/components/GidsDismissButton/GidsDismissButton.js.map +1 -0
  6. package/dist/components/GidsField/GidsField.d.ts +7 -0
  7. package/dist/components/GidsField/GidsField.d.ts.map +1 -0
  8. package/dist/components/GidsField/GidsField.js +27 -0
  9. package/dist/components/GidsField/GidsField.js.map +1 -0
  10. package/dist/components/GidsHeading/GidsHeading.d.ts +7 -0
  11. package/dist/components/GidsHeading/GidsHeading.d.ts.map +1 -0
  12. package/dist/components/GidsHeading/GidsHeading.js +45 -0
  13. package/dist/components/GidsHeading/GidsHeading.js.map +1 -0
  14. package/dist/components/GidsInput/GidsInput.d.ts +18 -0
  15. package/dist/components/GidsInput/GidsInput.d.ts.map +1 -0
  16. package/dist/components/GidsInput/GidsInput.js +28 -0
  17. package/dist/components/GidsInput/GidsInput.js.map +1 -0
  18. package/dist/components/GidsLink/GidsLink.d.ts.map +1 -1
  19. package/dist/components/GidsLink/GidsLink.js.map +1 -1
  20. package/dist/components/GidsLogo/GidsLogo.d.ts +8 -0
  21. package/dist/components/GidsLogo/GidsLogo.d.ts.map +1 -0
  22. package/dist/components/GidsLogo/GidsLogo.js +25 -0
  23. package/dist/components/GidsLogo/GidsLogo.js.map +1 -0
  24. package/dist/components/GidsNotification/GidsNotification.d.ts +4 -0
  25. package/dist/components/GidsNotification/GidsNotification.d.ts.map +1 -0
  26. package/dist/components/GidsNotification/GidsNotification.js +30 -0
  27. package/dist/components/GidsNotification/GidsNotification.js.map +1 -0
  28. package/dist/components/GidsOverlayProvider/GidsOverlayProvider.d.ts +7 -0
  29. package/dist/components/GidsOverlayProvider/GidsOverlayProvider.d.ts.map +1 -0
  30. package/dist/components/GidsOverlayProvider/GidsOverlayProvider.js +7 -0
  31. package/dist/components/GidsOverlayProvider/GidsOverlayProvider.js.map +1 -0
  32. package/dist/components/GidsPasswordField/GidsPasswordField.d.ts +16 -0
  33. package/dist/components/GidsPasswordField/GidsPasswordField.d.ts.map +1 -0
  34. package/dist/components/GidsPasswordField/GidsPasswordField.js +34 -0
  35. package/dist/components/GidsPasswordField/GidsPasswordField.js.map +1 -0
  36. package/dist/components/GidsRequirementsMeter/GidsRequirementsMeter.d.ts +6 -0
  37. package/dist/components/GidsRequirementsMeter/GidsRequirementsMeter.d.ts.map +1 -0
  38. package/dist/components/GidsRequirementsMeter/GidsRequirementsMeter.js +48 -0
  39. package/dist/components/GidsRequirementsMeter/GidsRequirementsMeter.js.map +1 -0
  40. package/dist/components/GidsSearchBar/GidsSearchBar.d.ts +9 -0
  41. package/dist/components/GidsSearchBar/GidsSearchBar.d.ts.map +1 -0
  42. package/dist/components/GidsSearchBar/GidsSearchBar.js +59 -0
  43. package/dist/components/GidsSearchBar/GidsSearchBar.js.map +1 -0
  44. package/dist/components/GidsSnackbar/GidsSnackbar.d.ts +4 -0
  45. package/dist/components/GidsSnackbar/GidsSnackbar.d.ts.map +1 -0
  46. package/dist/components/GidsSnackbar/GidsSnackbar.js +24 -0
  47. package/dist/components/GidsSnackbar/GidsSnackbar.js.map +1 -0
  48. package/dist/components/GidsStatusTag/GidsStatusTag.d.ts +6 -0
  49. package/dist/components/GidsStatusTag/GidsStatusTag.d.ts.map +1 -0
  50. package/dist/components/GidsStatusTag/GidsStatusTag.js +18 -0
  51. package/dist/components/GidsStatusTag/GidsStatusTag.js.map +1 -0
  52. package/dist/components/GidsStepper/GidsStepper.d.ts +8 -0
  53. package/dist/components/GidsStepper/GidsStepper.d.ts.map +1 -0
  54. package/dist/components/GidsStepper/GidsStepper.js +67 -0
  55. package/dist/components/GidsStepper/GidsStepper.js.map +1 -0
  56. package/dist/components/GidsStrengthMeter/GidsStrengthMeter.d.ts +6 -0
  57. package/dist/components/GidsStrengthMeter/GidsStrengthMeter.d.ts.map +1 -0
  58. package/dist/components/GidsStrengthMeter/GidsStrengthMeter.js +51 -0
  59. package/dist/components/GidsStrengthMeter/GidsStrengthMeter.js.map +1 -0
  60. package/dist/components/GidsTextField/GidsTextField.d.ts +13 -0
  61. package/dist/components/GidsTextField/GidsTextField.d.ts.map +1 -0
  62. package/dist/components/GidsTextField/GidsTextField.js +27 -0
  63. package/dist/components/GidsTextField/GidsTextField.js.map +1 -0
  64. package/dist/components/GidsTopNavigation/GidsTopNavigation.d.ts +9 -0
  65. package/dist/components/GidsTopNavigation/GidsTopNavigation.d.ts.map +1 -0
  66. package/dist/components/GidsTopNavigation/GidsTopNavigation.js +61 -0
  67. package/dist/components/GidsTopNavigation/GidsTopNavigation.js.map +1 -0
  68. package/dist/components/_GidsNotificationContainer/GidsNotificationContainer.d.ts +9 -0
  69. package/dist/components/_GidsNotificationContainer/GidsNotificationContainer.d.ts.map +1 -0
  70. package/dist/components/_GidsNotificationContainer/GidsNotificationContainer.js +73 -0
  71. package/dist/components/_GidsNotificationContainer/GidsNotificationContainer.js.map +1 -0
  72. package/dist/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.d.ts +6 -0
  73. package/dist/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.d.ts.map +1 -0
  74. package/dist/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.js +26 -0
  75. package/dist/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.js.map +1 -0
  76. package/dist/components/_GidsSnackbarContainer/GidsSnackbarContainer.d.ts +8 -0
  77. package/dist/components/_GidsSnackbarContainer/GidsSnackbarContainer.d.ts.map +1 -0
  78. package/dist/components/_GidsSnackbarContainer/GidsSnackbarContainer.js +37 -0
  79. package/dist/components/_GidsSnackbarContainer/GidsSnackbarContainer.js.map +1 -0
  80. package/dist/index.d.ts +19 -0
  81. package/dist/index.d.ts.map +1 -1
  82. package/dist/index.js +19 -0
  83. package/dist/index.js.map +1 -1
  84. package/dist/utils/domUtils.d.ts +2 -0
  85. package/dist/utils/domUtils.d.ts.map +1 -1
  86. package/dist/utils/domUtils.js +17 -0
  87. package/dist/utils/domUtils.js.map +1 -1
  88. package/package.json +3 -3
  89. package/src/components/GidsDismissButton/GidsDismissButton.ts +45 -0
  90. package/src/components/GidsField/GidsField.ts +55 -0
  91. package/src/components/GidsHeading/GidsHeading.ts +72 -0
  92. package/src/components/GidsInput/GidsInput.ts +64 -0
  93. package/src/components/GidsLink/GidsLink.ts +20 -20
  94. package/src/components/GidsLogo/GidsLogo.ts +60 -0
  95. package/src/components/GidsNotification/GidsNotification.ts +48 -0
  96. package/src/components/GidsOverlayProvider/GidsOverlayProvider.ts +16 -0
  97. package/src/components/GidsPasswordField/GidsPasswordField.ts +77 -0
  98. package/src/components/GidsRequirementsMeter/GidsRequirementsMeter.ts +71 -0
  99. package/src/components/GidsSearchBar/GidsSearchBar.ts +103 -0
  100. package/src/components/GidsSnackbar/GidsSnackbar.ts +40 -0
  101. package/src/components/GidsStatusTag/GidsStatusTag.ts +43 -0
  102. package/src/components/GidsStepper/GidsStepper.ts +94 -0
  103. package/src/components/GidsStrengthMeter/GidsStrengthMeter.ts +78 -0
  104. package/src/components/GidsTextField/GidsTextField.ts +59 -0
  105. package/src/components/GidsTopNavigation/GidsTopNavigation.ts +123 -0
  106. package/src/components/_GidsNotificationContainer/GidsNotificationContainer.ts +125 -0
  107. package/src/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.ts +50 -0
  108. package/src/components/_GidsSnackbarContainer/GidsSnackbarContainer.ts +68 -0
  109. package/src/index.ts +19 -0
  110. package/src/utils/domUtils.ts +75 -48
package/CHANGELOG.md CHANGED
@@ -1,5 +1,57 @@
1
1
  # @ganpatiinfo/gids-web-dom-reference
2
2
 
3
+ ## 4.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - f07488b: Developed `GidsOverlayProvider` component for all web platforms
8
+ - 1f21b8f: - Developed `GidsStatusTag` component for all web platforms
9
+ - f07488b: Developed `GidsSnackbar` component for all web platforms
10
+ - f07488b: Developed `GidsSnackbarContainer` component for all web platforms
11
+ - ce3edb7: - Developed `GidsRequirementsMeterLabel` private component for all web platforms
12
+ - ab624d1: - Developed `GidsTopNavigation` component in all web platforms
13
+ - 53cf25f: - Developed `GidsField` component in web component and available for all web platforms
14
+ - 8e959c0: - Developed `GidsSearchBar` component in all web platforms
15
+ - 53cf25f: - Developed `GidsTextField` component in web components in web core and available for all web platforms
16
+ - d93c657: - Developed `GidsNotificationContainer` component for all web platforms
17
+ - 53cf25f: - Developed `GidsInput` component in web components in web core and available for all web platforms
18
+ - 53cf25f: - Developed `GidsLogo` component in all web platforms
19
+ - a0f7d7b: - Developed `GidsHeading` component for all web platforms
20
+ - ce3edb7: Developed `GidsRequirementsMeter` component for all web platforms
21
+ - 8bbcdbc: - Developed `GidsStepper` component for all web platforms
22
+ - 53cf25f: - Developed `GidsDismissButton` for all web platforms
23
+ - d93c657: - Developed `GidsNotification` component for all web platforms
24
+ - 965993f: - Developed `GidsPasswordField` web component for all web platforms
25
+
26
+ ### Minor Changes
27
+
28
+ - 579aa0a: - Developed `GidsStrengthMeter` private component for all web platforms
29
+
30
+ ### Patch Changes
31
+
32
+ - Updated dependencies [f07488b]
33
+ - Updated dependencies [1f21b8f]
34
+ - Updated dependencies [579aa0a]
35
+ - Updated dependencies [f07488b]
36
+ - Updated dependencies [f07488b]
37
+ - Updated dependencies [ce3edb7]
38
+ - Updated dependencies [ab624d1]
39
+ - Updated dependencies [53cf25f]
40
+ - Updated dependencies [8e959c0]
41
+ - Updated dependencies [53cf25f]
42
+ - Updated dependencies [53cf25f]
43
+ - Updated dependencies [d93c657]
44
+ - Updated dependencies [53cf25f]
45
+ - Updated dependencies [53cf25f]
46
+ - Updated dependencies [a0f7d7b]
47
+ - Updated dependencies [ce3edb7]
48
+ - Updated dependencies [8bbcdbc]
49
+ - Updated dependencies [53cf25f]
50
+ - Updated dependencies [d93c657]
51
+ - Updated dependencies [965993f]
52
+ - @ganpatiinfo/gids-core-shared@4.0.0
53
+ - @ganpatiinfo/gids-web-shared@4.0.0
54
+
3
55
  ## 3.1.0
4
56
 
5
57
  ### Minor Changes
@@ -0,0 +1,8 @@
1
+ import { type GidsDismissButtonCommonProps } from '@ganpatiinfo/gids-core-shared';
2
+ import { type ClassValue } from '@ganpatiinfo/gids-web-shared';
3
+ export interface GidsDismissButtonDomProps extends GidsDismissButtonCommonProps {
4
+ onPressDismiss?: (this: HTMLButtonElement, event: Event) => void;
5
+ extraClasses?: ClassValue;
6
+ }
7
+ export declare const GidsDismissButtonDom: ({ appearance, size, disabled, extraClasses, onPressDismiss, label, }: GidsDismissButtonDomProps) => HTMLButtonElement;
8
+ //# sourceMappingURL=GidsDismissButton.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsDismissButton.d.ts","sourceRoot":"","sources":["../../../src/components/GidsDismissButton/GidsDismissButton.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,4BAA4B,EAAE,MAAM,+BAA+B,CAAC;AAClF,OAAO,EACL,KAAK,UAAU,EAEhB,MAAM,8BAA8B,CAAC;AAMtC,MAAM,WAAW,yBAA0B,SAAQ,4BAA4B;IAC7E,cAAc,CAAC,EAAE,CAAC,IAAI,EAAE,iBAAiB,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IACjE,YAAY,CAAC,EAAE,UAAU,CAAC;CAC3B;AAED,eAAO,MAAM,oBAAoB,GAAI,sEAOlC,yBAAyB,KAAG,iBAsB9B,CAAC"}
@@ -0,0 +1,20 @@
1
+ import { GidsDismissButtonWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import { GidsIconDom } from '../GidsIcon/GidsIcon.js';
3
+ import { toggleAttribute } from '../../utils/domUtils.js';
4
+ const { getGidsDismissButtonClassNames } = GidsDismissButtonWebUtils;
5
+ export const GidsDismissButtonDom = ({ appearance = 'subtle', size = 'md', disabled = false, extraClasses, onPressDismiss, label, }) => {
6
+ const buttonElement = document.createElement('button');
7
+ buttonElement.className = getGidsDismissButtonClassNames({ appearance, size }, extraClasses);
8
+ buttonElement.type = 'button';
9
+ buttonElement.setAttribute('aria-label', label);
10
+ toggleAttribute(buttonElement, 'disabled', disabled);
11
+ buttonElement.append(GidsIconDom({
12
+ name: 'cross',
13
+ appearance: 'regular',
14
+ }));
15
+ if (onPressDismiss) {
16
+ buttonElement.addEventListener('click', onPressDismiss);
17
+ }
18
+ return buttonElement;
19
+ };
20
+ //# sourceMappingURL=GidsDismissButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsDismissButton.js","sourceRoot":"","sources":["../../../src/components/GidsDismissButton/GidsDismissButton.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,yBAAyB,GAC1B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAE1D,MAAM,EAAE,8BAA8B,EAAE,GAAG,yBAAyB,CAAC;AAOrE,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,EACnC,UAAU,GAAG,QAAQ,EACrB,IAAI,GAAG,IAAI,EACX,QAAQ,GAAG,KAAK,EAChB,YAAY,EACZ,cAAc,EACd,KAAK,GACqB,EAAqB,EAAE;IACjD,MAAM,aAAa,GAAG,QAAQ,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC;IACvD,aAAa,CAAC,SAAS,GAAG,8BAA8B,CACtD,EAAE,UAAU,EAAE,IAAI,EAAE,EACpB,YAAY,CACb,CAAC;IACF,aAAa,CAAC,IAAI,GAAG,QAAQ,CAAC;IAC9B,aAAa,CAAC,YAAY,CAAC,YAAY,EAAE,KAAK,CAAC,CAAC;IAChD,eAAe,CAAC,aAAa,EAAE,UAAU,EAAE,QAAQ,CAAC,CAAC;IAErD,aAAa,CAAC,MAAM,CAClB,WAAW,CAAC;QACV,IAAI,EAAE,OAAO;QACb,UAAU,EAAE,SAAS;KACtB,CAAC,CACH,CAAC;IAEF,IAAI,cAAc,EAAE,CAAC;QACnB,aAAa,CAAC,gBAAgB,CAAC,OAAO,EAAE,cAAc,CAAC,CAAC;IAC1D,CAAC;IAED,OAAO,aAAa,CAAC;AACvB,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { type GidsFieldWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { type DomChildren } from '../../utils/domUtils.js';
3
+ export interface GidsFieldDomProps extends GidsFieldWebProps<DomChildren, DomChildren> {
4
+ extraClasses?: string;
5
+ }
6
+ export declare const GidsFieldDom: ({ children, count, disabled, label, helperText, statusText, status, extraClasses, }: GidsFieldDomProps) => HTMLElement;
7
+ //# sourceMappingURL=GidsField.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsField.d.ts","sourceRoot":"","sources":["../../../src/components/GidsField/GidsField.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACtE,OAAO,EAGL,KAAK,WAAW,EACjB,MAAM,yBAAyB,CAAC;AAEjC,MAAM,WAAW,iBAAkB,SAAQ,iBAAiB,CAC1D,WAAW,EACX,WAAW,CACZ;IACC,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,YAAY,GAAI,qFAS1B,iBAAiB,KAAG,WA+BtB,CAAC"}
@@ -0,0 +1,27 @@
1
+ import { appendAsChildren, toggleAttribute, } from '../../utils/domUtils.js';
2
+ export const GidsFieldDom = ({ children, count, disabled, label, helperText, statusText, status, extraClasses, }) => {
3
+ const field = document.createElement('gids-field');
4
+ if (count !== undefined) {
5
+ field.setAttribute('count', count);
6
+ }
7
+ else {
8
+ field.removeAttribute('count');
9
+ }
10
+ if (helperText !== undefined) {
11
+ field.setAttribute('helper-text', helperText);
12
+ }
13
+ if (statusText !== undefined) {
14
+ field.setAttribute('status-text', statusText);
15
+ }
16
+ if (status !== undefined) {
17
+ field.setAttribute('status', status);
18
+ }
19
+ toggleAttribute(field, 'disabled', disabled);
20
+ appendAsChildren(field, label);
21
+ appendAsChildren(field, children);
22
+ if (extraClasses) {
23
+ field.className = extraClasses;
24
+ }
25
+ return field;
26
+ };
27
+ //# sourceMappingURL=GidsField.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsField.js","sourceRoot":"","sources":["../../../src/components/GidsField/GidsField.ts"],"names":[],"mappings":"AACA,OAAO,EACL,gBAAgB,EAChB,eAAe,GAEhB,MAAM,yBAAyB,CAAC;AASjC,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,EAC3B,QAAQ,EACR,KAAK,EACL,QAAQ,EACR,KAAK,EACL,UAAU,EACV,UAAU,EACV,MAAM,EACN,YAAY,GACM,EAAe,EAAE;IACnC,MAAM,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,YAAY,CAAC,CAAC;IAEnD,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;QACxB,KAAK,CAAC,YAAY,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC;IACrC,CAAC;SAAM,CAAC;QACN,KAAK,CAAC,eAAe,CAAC,OAAO,CAAC,CAAC;IACjC,CAAC;IAED,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC7B,KAAK,CAAC,YAAY,CAAC,aAAa,EAAE,UAAU,CAAC,CAAC;IAChD,CAAC;IAED,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC7B,KAAK,CAAC,YAAY,CAAC,aAAa,EAAE,UAAU,CAAC,CAAC;IAChD,CAAC;IAED,IAAI,MAAM,KAAK,SAAS,EAAE,CAAC;QACzB,KAAK,CAAC,YAAY,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC;IACvC,CAAC;IAED,eAAe,CAAC,KAAK,EAAE,UAAU,EAAE,QAAQ,CAAC,CAAC;IAE7C,gBAAgB,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;IAC/B,gBAAgB,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;IAElC,IAAI,YAAY,EAAE,CAAC;QACjB,KAAK,CAAC,SAAS,GAAG,YAAY,CAAC;IACjC,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { GidsHeadingCommonProps } from '@ganpatiinfo/gids-core-shared';
2
+ import { DomChildren, DomNodeOrString } from '../../utils/domUtils.js';
3
+ export interface GidsHeadingDomProps extends GidsHeadingCommonProps<DomChildren, DomNodeOrString> {
4
+ extraClasses?: string;
5
+ }
6
+ export declare const GidsHeadingDom: (props: GidsHeadingDomProps) => HTMLDivElement;
7
+ //# sourceMappingURL=GidsHeading.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsHeading.d.ts","sourceRoot":"","sources":["../../../src/components/GidsHeading/GidsHeading.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,+BAA+B,CAAC;AAEvE,OAAO,EAEL,WAAW,EACX,eAAe,EAChB,MAAM,yBAAyB,CAAC;AAKjC,MAAM,WAAW,mBAAoB,SAAQ,sBAAsB,CACjE,WAAW,EACX,eAAe,CAChB;IACC,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,cAAc,GAAI,OAAO,mBAAmB,KAAG,cAqD3D,CAAC"}
@@ -0,0 +1,45 @@
1
+ import { GidsHeadingWebUtils } from '@ganpatiinfo/gids-web-shared';
2
+ import { appendAsChildren, } from '../../utils/domUtils.js';
3
+ import { GidsButtonGroupDom } from '../GidsButtonGroup/GidsButtonGroup.js';
4
+ const { getGidsHeadingClassNames } = GidsHeadingWebUtils;
5
+ export const GidsHeadingDom = (props) => {
6
+ const { heading, supportingText, level = 'section', children, extraClasses, } = props;
7
+ const headingContainer = document.createElement('div');
8
+ headingContainer.className = getGidsHeadingClassNames(extraClasses);
9
+ const contentContainer = document.createElement('div');
10
+ contentContainer.className = 'gids-heading__content-container';
11
+ if (heading) {
12
+ if (typeof heading === 'string') {
13
+ const headingEl = document.createElement('span');
14
+ headingEl.className =
15
+ level === 'section'
16
+ ? 'gids-heading__heading-text-section'
17
+ : 'gids-heading__heading-text-group';
18
+ headingEl.textContent = heading;
19
+ appendAsChildren(contentContainer, headingEl);
20
+ }
21
+ else {
22
+ contentContainer.append(heading);
23
+ }
24
+ }
25
+ if (supportingText) {
26
+ if (typeof supportingText === 'string') {
27
+ const supportingTextEl = document.createElement('span');
28
+ supportingTextEl.className =
29
+ level === 'section'
30
+ ? 'gids-heading__supporting-text-section'
31
+ : 'gids-heading__supporting-text-group';
32
+ supportingTextEl.textContent = supportingText;
33
+ appendAsChildren(contentContainer, supportingTextEl);
34
+ }
35
+ else {
36
+ contentContainer.append(supportingText);
37
+ }
38
+ }
39
+ headingContainer.appendChild(contentContainer);
40
+ if (children) {
41
+ headingContainer.append(GidsButtonGroupDom({ children: children, layout: 'wrap' }));
42
+ }
43
+ return headingContainer;
44
+ };
45
+ //# sourceMappingURL=GidsHeading.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsHeading.js","sourceRoot":"","sources":["../../../src/components/GidsHeading/GidsHeading.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EACL,gBAAgB,GAGjB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,kBAAkB,EAAE,MAAM,uCAAuC,CAAC;AAE3E,MAAM,EAAE,wBAAwB,EAAE,GAAG,mBAAmB,CAAC;AASzD,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,KAA0B,EAAkB,EAAE;IAC3E,MAAM,EACJ,OAAO,EACP,cAAc,EACd,KAAK,GAAG,SAAS,EACjB,QAAQ,EACR,YAAY,GACb,GAAG,KAAK,CAAC;IAEV,MAAM,g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AC;QACb,gBAAgB,CAAC,MAAM,CACrB,kBAAkB,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAC3D,CAAC;IACJ,CAAC;IAED,OAAO,gBAAgB,CAAC;AAC1B,CAAC,CAAC"}
@@ -0,0 +1,18 @@
1
+ import { type GidsInputWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ export interface HtmlInputAttributes {
3
+ id?: string;
4
+ placeholder?: string;
5
+ pattern?: string;
6
+ autocompleted?: string;
7
+ type?: string;
8
+ maxlength?: number;
9
+ }
10
+ export interface GidsInputDomProps extends GidsInputWebProps<Element, HtmlInputAttributes> {
11
+ onChange?: (this: HTMLInputElement, event: Event) => void;
12
+ onInput?: (this: HTMLInputElement, event: Event) => void;
13
+ onFocus?: (this: HTMLInputElement, event: Event) => void;
14
+ onBlur?: (this: HTMLInputElement, event: Event) => void;
15
+ extraClasses?: string;
16
+ }
17
+ export declare const GidsInputDom: ({ leadingIcon, leadingAccessory, trailingAccessory, trailingIcon, onChange, onInput, onFocus, onBlur, extraClasses, ...rest }: GidsInputDomProps) => HTMLElement;
18
+ //# sourceMappingURL=GidsInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsInput.d.ts","sourceRoot":"","sources":["../../../src/components/GidsInput/GidsInput.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AAGtE,MAAM,WAAW,mBAAmB;IAClC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,iBAAkB,SAAQ,iBAAiB,CAC1D,OAAO,EACP,mBAAmB,CACpB;IACC,QAAQ,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IAC1D,OAAO,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IACzD,OAAO,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IACzD,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IACxD,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,YAAY,GAAI,+HAW1B,iBAAiB,KAAG,WA6BtB,CAAC"}
@@ -0,0 +1,28 @@
1
+ import { assignToSlot } from '../../utils/domUtils.js';
2
+ export const GidsInputDom = ({ leadingIcon, leadingAccessory, trailingAccessory, trailingIcon, onChange, onInput, onFocus, onBlur, extraClasses, ...rest }) => {
3
+ const input = document.createElement('gids-input');
4
+ Object.assign(input, rest);
5
+ // Elements Slot
6
+ assignToSlot(input, 'leadingIcon', leadingIcon);
7
+ assignToSlot(input, 'leadingAccessory', leadingAccessory);
8
+ assignToSlot(input, 'trailingAccessory', trailingAccessory);
9
+ assignToSlot(input, 'trailingIcon', trailingIcon);
10
+ // Event Listeners
11
+ if (onChange) {
12
+ input.addEventListener('change', onChange);
13
+ }
14
+ if (onInput) {
15
+ input.addEventListener('input', onInput);
16
+ }
17
+ if (onFocus) {
18
+ input.addEventListener('focus', onFocus);
19
+ }
20
+ if (onBlur) {
21
+ input.addEventListener('blur', onBlur);
22
+ }
23
+ if (extraClasses) {
24
+ input.className = extraClasses;
25
+ }
26
+ return input;
27
+ };
28
+ //# sourceMappingURL=GidsInput.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsInput.js","sourceRoot":"","sources":["../../../src/components/GidsInput/GidsInput.ts"],"names":[],"mappings":"AACA,OAAO,E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ot":"","sources":["../../../src/components/GidsLink/GidsLink.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,EAAoB,KAAK,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAC7E,OAAO,EACN,KAAK,UAAU,EAEf,MAAM,8BAA8B,CAAC;AAItC,MAAM,WAAW,gBAAiB,SAAQ,mBAAmB,CAAC,WAAW,CAAC;IACzE,YAAY,CAAC,EAAE,UAAU,CAAC;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;CACzD;AAED,eAAO,MAAM,WAAW,GAAI,kDAMzB,gBAAgB,KAAG,iBAerB,CAAC"}
1
+ {"version":3,"file":"GidsLink.d.ts","sourceRoot":"","sources":["../../../src/components/GidsLink/GidsLink.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,EAAoB,KAAK,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAC7E,OAAO,EACL,KAAK,UAAU,EAEhB,MAAM,8BAA8B,CAAC;AAItC,MAAM,WAAW,gBAAiB,SAAQ,mBAAmB,CAAC,WAAW,CAAC;IACxE,YAAY,CAAC,EAAE,UAAU,CAAC;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;CAC1D;AAED,eAAO,MAAM,WAAW,GAAI,kDAMzB,gBAAgB,KAAG,iBAerB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"GidsLink.js","sourceRoot":"","sources":["../../../src/components/GidsLink/GidsLink.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAoB,MAAM,yBAAyB,CAAC;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,EAAE,QAAQ,CAAC,CAAC;IAExC,IAAI,IAAI,EAAE,CAAC;QACT,WAAW,CAAC,YAAY,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;IACzC,CAAC;IAED,IAAI,OAAO,EAAE,CAAC;QACZ,WAAW,CAAC,gBAAgB,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IACjD,CAAC;IAED,OAAO,WAAW,CAAC;AACrB,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { type ClassValue, type GidsLogoWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ export interface GidsLogoDomProps extends GidsLogoWebProps<string, string>, Omit<Partial<HTMLAnchorElement>, 'href' | 'class'> {
3
+ extraClasses?: ClassValue;
4
+ imgClasses?: ClassValue;
5
+ imgProps?: Omit<Partial<HTMLImageElement>, 'src' | 'alt' | 'class' | 'height'>;
6
+ }
7
+ export declare const GidsLogoDom: ({ src, href, alt, clickable, extraClasses, imgClasses, imgProps, imgHeight, ...restProps }: GidsLogoDomProps) => HTMLAnchorElement;
8
+ //# sourceMappingURL=GidsLogo.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsLogo.d.ts","sourceRoot":"","sources":["../../../src/components/GidsLogo/GidsLogo.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,UAAU,EACf,KAAK,gBAAgB,EAEtB,MAAM,8BAA8B,CAAC;AAKtC,MAAM,WAAW,gBACf,SACE,gBAAgB,CAAC,MAAM,EAAE,MAAM,CAAC,EAChC,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IACpD,YAAY,CAAC,EAAE,UAAU,CAAC;IAC1B,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,QAAQ,CAAC,EAAE,IAAI,CACb,OAAO,CAAC,gBAAgB,CAAC,EACzB,KAAK,GAAG,KAAK,GAAG,OAAO,GAAG,QAAQ,CACnC,CAAC;CACH;AAED,eAAO,MAAM,WAAW,GAAI,4FAUzB,gBAAgB,KAAG,iBA4BrB,CAAC"}
@@ -0,0 +1,25 @@
1
+ import { GidsLogoWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import clsx from 'clsx';
3
+ const { getGidsLogoClassNames } = GidsLogoWebUtils;
4
+ export const GidsLogoDom = ({ src, href, alt, clickable, extraClasses, imgClasses, imgProps, imgHeight = '100', ...restProps }) => {
5
+ const linkElement = document.createElement('a');
6
+ linkElement.className = getGidsLogoClassNames(extraClasses);
7
+ if (restProps) {
8
+ Object.assign(linkElement, restProps);
9
+ }
10
+ if (clickable && href && href !== '') {
11
+ linkElement.setAttribute('href', href);
12
+ }
13
+ if (src && src !== '') {
14
+ const imgElement = document.createElement('img');
15
+ imgElement.className = clsx(`gids-logo__img gids-logo__img-height-${imgHeight}`, imgClasses);
16
+ imgElement.setAttribute('src', src);
17
+ imgElement.setAttribute('alt', alt ? alt : 'logo');
18
+ if (imgProps) {
19
+ Object.assign(imgElement, imgProps);
20
+ }
21
+ linkElement.appendChild(imgElement);
22
+ }
23
+ return linkElement;
24
+ };
25
+ //# sourceMappingURL=GidsLogo.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsLogo.js","sourceRoot":"","sources":["../../../src/components/GidsLogo/GidsLogo.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,gBAAgB,GACjB,MAAM,8BAA8B,CAAC;AACtC,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,MAAM,EAAE,qBAAqB,EAAE,GAAG,gBAAgB,CAAC;AAcnD,MAAM,CAAC,MAAM,WAAW,GAAG,CAAC,EAC1B,GAAG,EACH,IAAI,EACJ,GAAG,EACH,SAAS,EACT,YAAY,EACZ,UAAU,EACV,QAAQ,EACR,SAAS,GAAG,KAAK,EACjB,GAAG,SAAS,EACK,EAAqB,EAAE;IACxC,MAAM,WAAW,GAAG,QAAQ,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;IAChD,WAAW,CAAC,SAAS,GAAG,qBAAqB,CAAC,YAAY,CAAC,CAAC;IAC5D,IAAI,SAAS,EAAE,CAAC;QACd,MAAM,CAAC,MAAM,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;IACxC,CAAC;IAED,IAAI,SAAS,IAAI,IAAI,IAAI,IAAI,KAAK,EAAE,EAAE,CAAC;QACrC,WAAW,CAAC,YAAY,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;IACzC,CAAC;IAED,IAAI,GAAG,IAAI,GAAG,KAAK,EAAE,EAAE,CAAC;QACtB,MAAM,UAAU,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QACjD,UAAU,CAAC,SAAS,GAAG,IAAI,CACzB,wCAAwC,SAAS,EAAE,EACnD,UAAU,CACX,CAAC;QACF,UAAU,CAAC,YAAY,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;QACpC,UAAU,CAAC,YAAY,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;QAEnD,IAAI,QAAQ,EAAE,CAAC;YACb,MAAM,CAAC,MAAM,CAAC,UAAU,EAAE,QAAQ,CAAC,CAAC;QACtC,CAAC;QAED,WAAW,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;IACtC,CAAC;IAED,OAAO,WAAW,CAAC;AACrB,CAAC,CAAC"}
@@ -0,0 +1,4 @@
1
+ import { type GidsNotificationWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ export type GidsNotificationDomProps = GidsNotificationWebProps;
3
+ export declare const GidsNotificationDom: ({ notificationTitle, message, pronunciation, appearance, show, onQueueNotification, buttonLabel, onButtonClick, position, timerInMs, }: GidsNotificationDomProps) => HTMLElement;
4
+ //# sourceMappingURL=GidsNotification.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsNotification.d.ts","sourceRoot":"","sources":["../../../src/components/GidsNotification/GidsNotification.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,8BAA8B,CAAC;AAE7E,MAAM,MAAM,wBAAwB,GAAG,wBAAwB,CAAC;AAEhE,eAAO,MAAM,mBAAmB,GAAI,wIAWjC,wBAAwB,KAAG,WAgC7B,CAAC"}
@@ -0,0 +1,30 @@
1
+ export const GidsNotificationDom = ({ notificationTitle, message, pronunciation, appearance = 'default', show, onQueueNotification, buttonLabel, onButtonClick, position = 'bottom-center', timerInMs, }) => {
2
+ const notification = document.createElement('gids-notification');
3
+ if (notificationTitle) {
4
+ notification.setAttribute('notification-title', notificationTitle);
5
+ }
6
+ if (message) {
7
+ notification.setAttribute('message', message);
8
+ }
9
+ if (pronunciation) {
10
+ notification.setAttribute('pronunciation', pronunciation);
11
+ }
12
+ if (appearance) {
13
+ notification.setAttribute('appearance', appearance);
14
+ }
15
+ notification.setAttribute('position', position);
16
+ notification.setAttribute('timer-in-ms', timerInMs ? `${timerInMs}` : '0');
17
+ notification.toggleAttribute('show', show ? show : false);
18
+ if (onQueueNotification) {
19
+ notification.addEventListener('queueNotification', onQueueNotification);
20
+ }
21
+ if (buttonLabel) {
22
+ notification.setAttribute('button-label', buttonLabel);
23
+ }
24
+ if (onButtonClick) {
25
+ // @ts-expect-error Expected
26
+ notification.onButtonClick = onButtonClick;
27
+ }
28
+ return notification;
29
+ };
30
+ //# sourceMappingURL=GidsNotification.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsNotification.js","sourceRoot":"","sources":["../../../src/components/GidsNotification/GidsNotification.ts"],"names":[],"mappings":"AAIA,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,EAClC,iBAAiB,EACjB,OAAO,EACP,aAAa,EACb,UAAU,GAAG,SAAS,EACtB,IAAI,EACJ,mBAAmB,EACnB,WAAW,EACX,aAAa,EACb,QAAQ,GAAG,eAAe,EAC1B,SAAS,GACgB,EAAe,EAAE;IAC1C,MAAM,YAAY,GAAG,QAAQ,CAAC,aAAa,CAAC,mBAAmB,CAAC,CAAC;IAEjE,IAAI,iBAAiB,EAAE,CAAC;QACtB,YAAY,CAAC,YAAY,CAAC,oBAAoB,EAAE,iBAAiB,CAAC,CAAC;IACrE,CAAC;IACD,IAAI,OAAO,EAAE,CAAC;QACZ,YAAY,CAAC,YAAY,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;IAChD,CAAC;IACD,IAAI,aAAa,EAAE,CAAC;QAClB,YAAY,CAAC,YAAY,CAAC,eAAe,EAAE,aAAa,CAAC,CAAC;IAC5D,CAAC;IACD,IAAI,UAAU,EAAE,CAAC;QACf,YAAY,CAAC,YAAY,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;IACtD,CAAC;IACD,YAAY,CAAC,YAAY,CAAC,UAAU,EAAE,QAAQ,CAAC,CAAC;IAChD,YAAY,CAAC,YAAY,CAAC,aAAa,EAAE,SAAS,CAAC,CAAC,CAAC,GAAG,SAAS,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IAE3E,YAAY,CAAC,eAAe,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;IAE1D,IAAI,mBAAmB,EAAE,CAAC;QACxB,YAAY,CAAC,gBAAgB,CAAC,mBAAmB,EAAE,mBAAmB,CAAC,CAAC;IAC1E,CAAC;IACD,IAAI,WAAW,EAAE,CAAC;QAChB,YAAY,CAAC,YAAY,CAAC,cAAc,EAAE,WAAW,CAAC,CAAC;IACzD,CAAC;IACD,IAAI,aAAa,EAAE,CAAC;QAClB,4BAA4B;QAC5B,YAAY,CAAC,aAAa,GAAG,aAAa,CAAC;IAC7C,CAAC;IAED,OAAO,YAAY,CAAC;AACtB,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { GidsOverlayProviderCommonProps } from '@ganpatiinfo/gids-core-shared';
2
+ import { DomChildren } from '../../utils/domUtils.js';
3
+ export interface GidsOverlayProviderDomProps extends GidsOverlayProviderCommonProps<DomChildren> {
4
+ extraClasses?: string;
5
+ }
6
+ export declare const GidsOverlayProviderDom: ({ children, }: GidsOverlayProviderDomProps) => HTMLElement;
7
+ //# sourceMappingURL=GidsOverlayProvider.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsOverlayProvider.d.ts","sourceRoot":"","sources":["../../../src/components/GidsOverlayProvider/GidsOverlayProvider.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,8BAA8B,EAAE,MAAM,+BAA+B,CAAC;AAC/E,OAAO,EAAoB,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAExE,MAAM,WAAW,2BAA4B,SAAQ,8BAA8B,CAAC,WAAW,CAAC;IAC9F,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,sBAAsB,GAAI,eAEpC,2BAA2B,KAAG,WAMhC,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { appendAsChildren } from '../../utils/domUtils.js';
2
+ export const GidsOverlayProviderDom = ({ children, }) => {
3
+ const overlayProvider = document.createElement('gids-overlay-provider');
4
+ appendAsChildren(overlayProvider, children);
5
+ return overlayProvider;
6
+ };
7
+ //# sourceMappingURL=GidsOverlayProvider.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsOverlayProvider.js","sourceRoot":"","sources":["../../../src/components/GidsOverlayProvider/GidsOverlayProvider.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAe,MAAM,yBAAyB,CAAC;AAMxE,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,EACrC,QAAQ,GACoB,EAAe,EAAE;IAC7C,MAAM,eAAe,GAAG,QAAQ,CAAC,aAAa,CAAC,uBAAuB,CAAC,CAAC;IAExE,gBAAgB,CAAC,eAAe,EAAE,QAAQ,CAAC,CAAC;IAE5C,OAAO,eAAe,CAAC;AACzB,CAAC,CAAC"}
@@ -0,0 +1,16 @@
1
+ import { type GidsPasswordFieldWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { type HtmlInputAttributes } from '../GidsInput/GidsInput.js';
3
+ export interface GidsPasswordFieldDomProps extends GidsPasswordFieldWebProps<Element, HtmlInputAttributes> {
4
+ info?: Element;
5
+ className?: string;
6
+ onGidsPasswordFieldClear?: (event: CustomEvent<void>) => void;
7
+ onGidsPasswordFieldRevealPassword?: (event: CustomEvent<{
8
+ passwordRevealed: boolean;
9
+ }>) => void;
10
+ onChange?: (event: Event) => void;
11
+ onInput?: (event: InputEvent) => void;
12
+ onFocus?: (event: FocusEvent) => void;
13
+ onBlur?: (event: FocusEvent) => void;
14
+ }
15
+ export declare const GidsPasswordFieldDom: (props: GidsPasswordFieldDomProps) => HTMLElement;
16
+ //# sourceMappingURL=GidsPasswordField.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsPasswordField.d.ts","sourceRoot":"","sources":["../../../src/components/GidsPasswordField/GidsPasswordField.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,8BAA8B,CAAC;AAE9E,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAErE,MAAM,WAAW,yBAA0B,SAAQ,yBAAyB,CAC1E,OAAO,EACP,mBAAmB,CACpB;IACC,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,wBAAwB,CAAC,EAAE,CAAC,KAAK,EAAE,WAAW,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC;IAC9D,iCAAiC,CAAC,EAAE,CAClC,KAAK,EAAE,WAAW,CAAC;QAAE,gBAAgB,EAAE,OAAO,CAAA;KAAE,CAAC,KAC9C,IAAI,CAAC;IACV,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IAClC,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;IACtC,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;IACtC,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;CACtC;AAED,eAAO,MAAM,oBAAoB,GAC/B,OAAO,yBAAyB,KAC/B,WAsDF,CAAC"}
@@ -0,0 +1,34 @@
1
+ import { assignToSlot } from '../../utils/domUtils.js';
2
+ export const GidsPasswordFieldDom = (props) => {
3
+ const { info, leadingIcon, onGidsPasswordFieldClear, onGidsPasswordFieldRevealPassword, onChange, onInput, onFocus, onBlur, ...restProps } = props;
4
+ const passwordFieldComponent = document.createElement('gids-password-field');
5
+ Object.assign(passwordFieldComponent, restProps);
6
+ passwordFieldComponent.setAttribute('type', 'password');
7
+ assignToSlot(passwordFieldComponent, 'info', info);
8
+ assignToSlot(passwordFieldComponent, 'leadingIcon', leadingIcon);
9
+ if (onChange) {
10
+ passwordFieldComponent.addEventListener('change', onChange);
11
+ }
12
+ if (onInput) {
13
+ passwordFieldComponent.addEventListener('input', onInput);
14
+ }
15
+ if (onFocus) {
16
+ passwordFieldComponent.addEventListener('focus', onFocus);
17
+ }
18
+ if (onBlur) {
19
+ passwordFieldComponent.addEventListener('blur', onBlur);
20
+ }
21
+ if (onGidsPasswordFieldClear) {
22
+ // @ts-expect-error This is a custom event so ts complaining
23
+ passwordFieldComponent.addEventListener('gidsPasswordFieldClear', onGidsPasswordFieldClear);
24
+ }
25
+ if (onGidsPasswordFieldRevealPassword) {
26
+ // @ts-expect-error This is a custom event so ts complaining
27
+ passwordFieldComponent.addEventListener('gidsPasswordFieldRevealPassword', (event) => {
28
+ // Stencil data is always nested inside 'detail'
29
+ onGidsPasswordFieldRevealPassword(event.detail);
30
+ });
31
+ }
32
+ return passwordFieldComponent;
33
+ };
34
+ //# sourceMappingURL=GidsPasswordField.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsPasswordField.js","sourceRoot":"","sources":["../../../src/components/GidsPasswordField/GidsPasswordField.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,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,gDAAgD;YAChD,iCAAiC,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QAClD,CAAC,CACF,CAAC;IACJ,CAAC;IAED,OAAO,sBAAsB,CAAC;AAChC,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { type GidsRequirementsMeterCommonProps } from '@ganpatiinfo/gids-core-shared';
2
+ export interface GidsRequirementsMeterDomProps extends GidsRequirementsMeterCommonProps {
3
+ extraClasses?: string;
4
+ }
5
+ export declare const GidsRequirementsMeterDom: (props: GidsRequirementsMeterDomProps) => HTMLDivElement;
6
+ //# sourceMappingURL=GidsRequirementsMeter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsRequirementsMeter.d.ts","sourceRoot":"","sources":["../../../src/components/GidsRequirementsMeter/GidsRequirementsMeter.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,gCAAgC,EAGtC,MAAM,+BAA+B,CAAC;AAQvC,MAAM,WAAW,6BAA8B,SAAQ,gCAAgC;IACrF,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,wBAAwB,GACnC,OAAO,6BAA6B,KACnC,cAoDF,CAAC"}
@@ -0,0 +1,48 @@
1
+ import { GidsRequirementsMeterCommonUtils, } from '@ganpatiinfo/gids-core-shared';
2
+ import { GidsRequirementsMeterWebUtils } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsRequirementsMeterLabelDom } from '../_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.js';
4
+ import { minLengthRuleCanBeApplied } from '@ganpatiinfo/gids-core-shared/dist/components/GidsRequirementsMeter/GidsRequirementsMeterCommonUtils.js';
5
+ const { getGidsRequirementsMeterClassNames } = GidsRequirementsMeterWebUtils;
6
+ const { checkRequirementRuleSatisfied } = GidsRequirementsMeterCommonUtils;
7
+ export const GidsRequirementsMeterDom = (props) => {
8
+ const { text, textMinLength, requirements = [], extraClasses } = props;
9
+ const requirementsMeter = document.createElement('div');
10
+ requirementsMeter.className =
11
+ getGidsRequirementsMeterClassNames(extraClasses);
12
+ const renderRequirements = (isSatisfied, requirement) => {
13
+ if (isSatisfied) {
14
+ requirementsMeter.append(GidsRequirementsMeterLabelDom({
15
+ label: requirement.requirementText,
16
+ status: 'success',
17
+ }));
18
+ }
19
+ else {
20
+ requirementsMeter.append(GidsRequirementsMeterLabelDom({
21
+ label: requirement.requirementText,
22
+ status: 'error',
23
+ }));
24
+ }
25
+ };
26
+ requirements.map((requirement) => {
27
+ if (requirement?.requirementText && requirement?.requirementRule) {
28
+ const isSatisfied = checkRequirementRuleSatisfied({
29
+ rule: requirement.requirementRule,
30
+ textMinLength,
31
+ text,
32
+ });
33
+ if (requirement.requirementRule == 'include-min-length') {
34
+ if (minLengthRuleCanBeApplied({
35
+ requirementRule: requirement.requirementRule,
36
+ textMinLength,
37
+ })) {
38
+ renderRequirements(isSatisfied, requirement);
39
+ }
40
+ }
41
+ else {
42
+ renderRequirements(isSatisfied, requirement);
43
+ }
44
+ }
45
+ });
46
+ return requirementsMeter;
47
+ };
48
+ //# sourceMappingURL=GidsRequirementsMeter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsRequirementsMeter.js","sourceRoot":"","sources":["../../../src/components/GidsRequirementsMeter/GidsRequirementsMeter.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,gCAAgC,GAEjC,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,6BAA6B,EAAE,MAAM,8BAA8B,CAAC;AAC7E,OAAO,EAAE,6BAA6B,EAAE,MAAM,8DAA8D,CAAC;AAC7G,OAAO,EAAE,yBAAyB,EAAE,MAAM,yGAAyG,CAAC;AAEpJ,MAAM,EAAE,kCAAkC,EAAE,GAAG,6BAA6B,CAAC;AAC7E,MAAM,EAAE,6BAA6B,EAAE,GAAG,gCAAgC,CAAC;AAM3E,MAAM,CAAC,MAAM,wBAAwB,GAAG,CACtC,KAAoC,EACpB,EAAE;IAClB,MAAM,EAAE,IAAI,EAAE,aAAa,E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CAAC"}
@@ -0,0 +1,9 @@
1
+ import { type GidsSearchBarWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { type HtmlInputAttributes } from '../GidsInput/GidsInput.js';
3
+ import { GidsTextFieldDomProps } from '../GidsTextField/GidsTextField.js';
4
+ export interface GidsSearchBarDomProps extends GidsSearchBarWebProps<Element, HtmlInputAttributes>, Pick<GidsTextFieldDomProps, 'className' | 'onChange' | 'onInput' | 'onFocus' | 'onBlur'> {
5
+ wrapperClass?: string;
6
+ onGidsSearchBarClear?: (event: CustomEvent<void>) => void;
7
+ }
8
+ export declare const GidsSearchBarDom: (props: GidsSearchBarDomProps) => HTMLDivElement;
9
+ //# sourceMappingURL=GidsSearchBar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSearchBar.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSearchBar/GidsSearchBar.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,qBAAqB,EAE3B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AACrE,OAAO,EAEL,qBAAqB,EACtB,MAAM,mCAAmC,CAAC;AAO3C,MAAM,WAAW,qBACf,SACE,qBAAqB,CAAC,OAAO,EAAE,mBAAmB,CAAC,EACnD,IAAI,CACF,qBAAqB,EACrB,WAAW,GAAG,UAAU,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,CAC5D;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,oBAAoB,CAAC,EAAE,CAAC,KAAK,EAAE,WAAW,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC;CAC3D;AAED,eAAO,MAAM,gBAAgB,GAC3B,OAAO,qBAAqB,KAC3B,cA0EF,CAAC"}
@@ -0,0 +1,59 @@
1
+ import { GidsSearchBarWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import { GidsTextFieldDom, } from '../GidsTextField/GidsTextField.js';
3
+ import { GidsIconDom } from '../GidsIcon/GidsIcon.js';
4
+ import { GidsSearchBarCommonUtils } from '@ganpatiinfo/gids-core-shared';
5
+ const { getSearchBarValue } = GidsSearchBarCommonUtils;
6
+ const { getSearchBarType, getSearchBarClassNames } = GidsSearchBarWebUtils;
7
+ export const GidsSearchBarDom = (props) => {
8
+ const { wrapperClass, leadingIcon, onGidsSearchBarClear, onChange, onInput, onFocus, onBlur, type = 'default', value = '', inputProps, ...restProps } = props;
9
+ const newValue = getSearchBarValue(value);
10
+ const textFieldType = getSearchBarType(type);
11
+ // 2. Render your initial DOM exactly once
12
+ const searchBar = document.createElement('div');
13
+ searchBar.className = getSearchBarClassNames(wrapperClass);
14
+ const updatedLeadingIcon = leadingIcon
15
+ ? leadingIcon
16
+ : GidsIconDom({
17
+ name: 'search',
18
+ appearance: 'regular',
19
+ size: 'md',
20
+ });
21
+ const gidsSearchBarClear = (event) => {
22
+ onGidsSearchBarClear?.(event);
23
+ };
24
+ const gidsOnChange = (event) => {
25
+ if (onChange) {
26
+ onChange(event);
27
+ }
28
+ };
29
+ const gidsOnInput = (event) => {
30
+ if (onInput) {
31
+ onInput(event);
32
+ }
33
+ };
34
+ const textFieldProps = {
35
+ ...restProps,
36
+ leadingAccessory: undefined,
37
+ showClearButton: true,
38
+ leadingIcon: updatedLeadingIcon,
39
+ onGidsTextFieldClear: gidsSearchBarClear,
40
+ onChange: gidsOnChange,
41
+ onInput: gidsOnInput,
42
+ onFocus,
43
+ onBlur,
44
+ type: textFieldType,
45
+ label: undefined,
46
+ value: newValue,
47
+ inputProps: {
48
+ ...inputProps,
49
+ placeholder: inputProps?.placeholder && inputProps.placeholder !== ''
50
+ ? inputProps.placeholder
51
+ : 'Search',
52
+ },
53
+ };
54
+ // 3. Create the text field once
55
+ const textField = GidsTextFieldDom(textFieldProps);
56
+ searchBar.append(textField);
57
+ return searchBar;
58
+ };
59
+ //# sourceMappingURL=GidsSearchBar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSearchBar.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,CAAC,KAAY,EAAE,EAAE;QACpC,IAAI,QAAQ,EAAE,CAAC;YACb,QAAQ,CAAC,KAAK,CAAC,CAAC;QAClB,CAAC;IACH,CAAC,CAAC;IAEF,MAAM,WAAW,GAAG,CAAC,KAAiB,EAAE,EAAE;QACxC,IAAI,OAAO,EAAE,CAAC;YACZ,OAAO,CAAC,KAAK,CAAC,CAAC;QACjB,CAAC;IACH,CAAC,CAAC;IAEF,MAAM,cAAc,GAA0B;QAC5C,GAAG,SAAS;QACZ,gBAAgB,EAAE,SAAS;QAC3B,eAAe,EAAE,IAAI;QACrB,WAAW,EAAE,kBAAkB;QAC/B,oBAAoB,EAAE,kBAAkB;QACxC,QAAQ,EAAE,YAAY;QACtB,OAAO,EAAE,WAAW;QACpB,OAAO;QACP,MAAM;QACN,IAAI,EAAE,aAAa;QACnB,KAAK,EAAE,SAAS;QAChB,KAAK,EAAE,QAAQ;QACf,UAAU,EAAE;YACV,GAAG,UAAU;YACb,WAAW,EACT,UAAU,EAAE,WAAW,IAAI,UAAU,CAAC,WAAW,KAAK,EAAE;gBACtD,CAAC,CAAC,UAAU,CAAC,WAAW;gBACxB,CAAC,CAAC,QAAQ;SACf;KACF,CAAC;IAEF,gCAAgC;IAChC,MAAM,SAAS,GAAG,gBAAgB,CAAC,cAAc,CAAC,CAAC;IAEnD,SAAS,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;IAE5B,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC"}
@@ -0,0 +1,4 @@
1
+ import { type GidsSnackbarWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ export type GidsSnackbarDomProps = GidsSnackbarWebProps;
3
+ export declare const GidsSnackbarDom: ({ message, appearance, show, onQueueSnackbar, buttonLabel, onButtonClick, position, timerInMs, }: GidsSnackbarDomProps) => HTMLElement;
4
+ //# sourceMappingURL=GidsSnackbar.d.ts.map