@ganpatiinfo/gids-web-dom-reference 3.1.0 → 5.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 (129) hide show
  1. package/CHANGELOG.md +75 -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/GidsScrim/GidsScrim.d.ts +7 -0
  41. package/dist/components/GidsScrim/GidsScrim.d.ts.map +1 -0
  42. package/dist/components/GidsScrim/GidsScrim.js +12 -0
  43. package/dist/components/GidsScrim/GidsScrim.js.map +1 -0
  44. package/dist/components/GidsSearchBar/GidsSearchBar.d.ts +9 -0
  45. package/dist/components/GidsSearchBar/GidsSearchBar.d.ts.map +1 -0
  46. package/dist/components/GidsSearchBar/GidsSearchBar.js +59 -0
  47. package/dist/components/GidsSearchBar/GidsSearchBar.js.map +1 -0
  48. package/dist/components/GidsSegmentedControl/GidsSegmentedControl.d.ts +2 -2
  49. package/dist/components/GidsSegmentedControl/GidsSegmentedControl.d.ts.map +1 -1
  50. package/dist/components/GidsSegmentedControl/GidsSegmentedControl.js.map +1 -1
  51. package/dist/components/GidsSegmentedTabItem/GidsSegmentedTabItem.d.ts +3 -3
  52. package/dist/components/GidsSegmentedTabItem/GidsSegmentedTabItem.d.ts.map +1 -1
  53. package/dist/components/GidsSegmentedTabItem/GidsSegmentedTabItem.js +14 -1
  54. package/dist/components/GidsSegmentedTabItem/GidsSegmentedTabItem.js.map +1 -1
  55. package/dist/components/GidsSnackbar/GidsSnackbar.d.ts +4 -0
  56. package/dist/components/GidsSnackbar/GidsSnackbar.d.ts.map +1 -0
  57. package/dist/components/GidsSnackbar/GidsSnackbar.js +24 -0
  58. package/dist/components/GidsSnackbar/GidsSnackbar.js.map +1 -0
  59. package/dist/components/GidsStatusTag/GidsStatusTag.d.ts +6 -0
  60. package/dist/components/GidsStatusTag/GidsStatusTag.d.ts.map +1 -0
  61. package/dist/components/GidsStatusTag/GidsStatusTag.js +18 -0
  62. package/dist/components/GidsStatusTag/GidsStatusTag.js.map +1 -0
  63. package/dist/components/GidsStepper/GidsStepper.d.ts +8 -0
  64. package/dist/components/GidsStepper/GidsStepper.d.ts.map +1 -0
  65. package/dist/components/GidsStepper/GidsStepper.js +67 -0
  66. package/dist/components/GidsStepper/GidsStepper.js.map +1 -0
  67. package/dist/components/GidsStrengthMeter/GidsStrengthMeter.d.ts +6 -0
  68. package/dist/components/GidsStrengthMeter/GidsStrengthMeter.d.ts.map +1 -0
  69. package/dist/components/GidsStrengthMeter/GidsStrengthMeter.js +51 -0
  70. package/dist/components/GidsStrengthMeter/GidsStrengthMeter.js.map +1 -0
  71. package/dist/components/GidsTextField/GidsTextField.d.ts +13 -0
  72. package/dist/components/GidsTextField/GidsTextField.d.ts.map +1 -0
  73. package/dist/components/GidsTextField/GidsTextField.js +27 -0
  74. package/dist/components/GidsTextField/GidsTextField.js.map +1 -0
  75. package/dist/components/GidsTopNavigation/GidsTopNavigation.d.ts +9 -0
  76. package/dist/components/GidsTopNavigation/GidsTopNavigation.d.ts.map +1 -0
  77. package/dist/components/GidsTopNavigation/GidsTopNavigation.js +61 -0
  78. package/dist/components/GidsTopNavigation/GidsTopNavigation.js.map +1 -0
  79. package/dist/components/_GidsNotificationContainer/GidsNotificationContainer.d.ts +9 -0
  80. package/dist/components/_GidsNotificationContainer/GidsNotificationContainer.d.ts.map +1 -0
  81. package/dist/components/_GidsNotificationContainer/GidsNotificationContainer.js +73 -0
  82. package/dist/components/_GidsNotificationContainer/GidsNotificationContainer.js.map +1 -0
  83. package/dist/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.d.ts +6 -0
  84. package/dist/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.d.ts.map +1 -0
  85. package/dist/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.js +26 -0
  86. package/dist/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.js.map +1 -0
  87. package/dist/components/_GidsSideMenuItem/GidsSideMenuItem.d.ts +8 -0
  88. package/dist/components/_GidsSideMenuItem/GidsSideMenuItem.d.ts.map +1 -0
  89. package/dist/components/_GidsSideMenuItem/GidsSideMenuItem.js +62 -0
  90. package/dist/components/_GidsSideMenuItem/GidsSideMenuItem.js.map +1 -0
  91. package/dist/components/_GidsSnackbarContainer/GidsSnackbarContainer.d.ts +8 -0
  92. package/dist/components/_GidsSnackbarContainer/GidsSnackbarContainer.d.ts.map +1 -0
  93. package/dist/components/_GidsSnackbarContainer/GidsSnackbarContainer.js +37 -0
  94. package/dist/components/_GidsSnackbarContainer/GidsSnackbarContainer.js.map +1 -0
  95. package/dist/index.d.ts +21 -0
  96. package/dist/index.d.ts.map +1 -1
  97. package/dist/index.js +21 -0
  98. package/dist/index.js.map +1 -1
  99. package/dist/utils/domUtils.d.ts +2 -0
  100. package/dist/utils/domUtils.d.ts.map +1 -1
  101. package/dist/utils/domUtils.js +17 -0
  102. package/dist/utils/domUtils.js.map +1 -1
  103. package/package.json +3 -3
  104. package/src/components/GidsDismissButton/GidsDismissButton.ts +45 -0
  105. package/src/components/GidsField/GidsField.ts +55 -0
  106. package/src/components/GidsHeading/GidsHeading.ts +72 -0
  107. package/src/components/GidsInput/GidsInput.ts +64 -0
  108. package/src/components/GidsLink/GidsLink.ts +20 -20
  109. package/src/components/GidsLogo/GidsLogo.ts +60 -0
  110. package/src/components/GidsNotification/GidsNotification.ts +48 -0
  111. package/src/components/GidsOverlayProvider/GidsOverlayProvider.ts +16 -0
  112. package/src/components/GidsPasswordField/GidsPasswordField.ts +77 -0
  113. package/src/components/GidsRequirementsMeter/GidsRequirementsMeter.ts +71 -0
  114. package/src/components/GidsScrim/GidsScrim.ts +25 -0
  115. package/src/components/GidsSearchBar/GidsSearchBar.ts +103 -0
  116. package/src/components/GidsSegmentedControl/GidsSegmentedControl.ts +3 -2
  117. package/src/components/GidsSegmentedTabItem/GidsSegmentedTabItem.ts +23 -2
  118. package/src/components/GidsSnackbar/GidsSnackbar.ts +40 -0
  119. package/src/components/GidsStatusTag/GidsStatusTag.ts +43 -0
  120. package/src/components/GidsStepper/GidsStepper.ts +94 -0
  121. package/src/components/GidsStrengthMeter/GidsStrengthMeter.ts +78 -0
  122. package/src/components/GidsTextField/GidsTextField.ts +59 -0
  123. package/src/components/GidsTopNavigation/GidsTopNavigation.ts +124 -0
  124. package/src/components/_GidsNotificationContainer/GidsNotificationContainer.ts +125 -0
  125. package/src/components/_GidsRequirementsMeterLabel/GidsRequirementsMeterLabel.ts +50 -0
  126. package/src/components/_GidsSideMenuItem/GidsSideMenuItem.ts +108 -0
  127. package/src/components/_GidsSnackbarContainer/GidsSnackbarContainer.ts +68 -0
  128. package/src/index.ts +21 -0
  129. package/src/utils/domUtils.ts +75 -48
@@ -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.js","sourceRoot":"","sources":["../../../src/components/GidsSearchBar/GidsSearchBar.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,qBAAqB,GACtB,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EACL,gBAAgB,GAEjB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC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,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"}
@@ -1,7 +1,7 @@
1
1
  import { GidsSegmentedTabItemPressedReturnedProps, type GidsSegmentedControlCommonProps } from '@ganpatiinfo/gids-core-shared';
2
2
  import { type ClassValue } from '@ganpatiinfo/gids-web-shared';
3
- import { type DomNodeOrString } from '../../utils/domUtils.js';
4
- export interface GidsSegmentedControlDomProps extends GidsSegmentedControlCommonProps<DomNodeOrString, string> {
3
+ import { DomChildren, type DomNodeOrString } from '../../utils/domUtils.js';
4
+ export interface GidsSegmentedControlDomProps extends GidsSegmentedControlCommonProps<DomNodeOrString, string, DomChildren> {
5
5
  onPress?: (props: GidsSegmentedTabItemPressedReturnedProps) => void;
6
6
  className?: ClassValue;
7
7
  }
@@ -1 +1 @@
1
- {"version":3,"file":"GidsSegmentedControl.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSegmentedControl/GidsSegmentedControl.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wCAAwC,EACxC,KAAK,+BAA+B,EACrC,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,KAAK,UAAU,EAEhB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAK/D,MAAM,WAAW,4BAA6B,SAAQ,+BAA+B,CACnF,eAAe,EACf,MAAM,CACP;IACC,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,wCAAwC,KAAK,IAAI,CAAC;IACpE,SAAS,CAAC,EAAE,UAAU,CAAC;CACxB;AAED,eAAO,MAAM,uBAAuB,GAAI,0CAKrC,4BAA4B,KAAG,cAgDjC,CAAC"}
1
+ {"version":3,"file":"GidsSegmentedControl.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSegmentedControl/GidsSegmentedControl.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wCAAwC,EACxC,KAAK,+BAA+B,EACrC,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,KAAK,UAAU,EAEhB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,KAAK,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAK5E,MAAM,WAAW,4BAA6B,SAAQ,+BAA+B,CACnF,eAAe,EACf,MAAM,EACN,WAAW,CACZ;IACC,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,wCAAwC,KAAK,IAAI,CAAC;IACpE,SAAS,CAAC,EAAE,UAAU,CAAC;CACxB;AAED,eAAO,MAAM,uBAAuB,GAAI,0CAKrC,4BAA4B,KAAG,cAgDjC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"GidsSegmentedControl.js","sourceRoot":"","sources":["../../../src/components/GidsSegmentedControl/GidsSegmentedControl.ts"],"names":[],"mappings":"AAIA,OAAO,EAEL,4BAA4B,GAC7B,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,uBAAuB,EAAE,MAAM,iDAAiD,CAAC;AAE1F,MAAM,EAAE,iCAAiC,EAAE,GAAG,4BAA4B,CAAC;AAU3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AAC;qBACF,CAAC,CAAC;oBAEH,gBAAgB,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;gBAC3C,CAAC,CAAC,CAAC;YACL,CAAC;QACH,CAAC,CAAC;QAEF,iBAAiB;QACjB,UAAU,EAAE,CAAC;IACf,CAAC;IAED,OAAO,gBAAgB,CAAC;AAC1B,CAAC,CAAC"}
1
+ {"version":3,"file":"GidsSegmentedControl.js","sourceRoot":"","sources":["../../../src/components/GidsSegmentedControl/GidsSegmentedControl.ts"],"names":[],"mappings":"AAIA,OAAO,EAEL,4BAA4B,GAC7B,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,uBAAuB,EAAE,MAAM,iDAAiD,CAAC;AAE1F,MAAM,EAAE,iCAAiC,EAAE,GAAG,4BAA4B,CAAC;AAW3E,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,EACtC,KAAK,GAAG,WAAW,EACnB,QAAQ,EACR,OAAO,EACP,SAAS,GACoB,EAAkB,EAAE;IACjD,MAAM,gBAAgB,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IACvD,gBAAgB,CAAC,SAAS,GAAG,iCAAiC,CAC5D,EAAE,KAAK,EAAE,EACT,SAAS,CACV,CAAC;IAEF,IAAI,QAAQ,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACpC,iDAAiD;QACjD,MAAM,UAAU,GAAG,CAAC,aAAsB,EAAE,EAAE;YAC5C,sBAAsB;YACtB,gBAAgB,CAAC,SAAS,GAAG,EAAE,CAAC;YAEhC,IAAI,QAAQ,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;gBACpC,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,KAAK,EAAE,EAAE;oBAClC,oCAAoC;oBACpC,8EAA8E;oBAE9E,IAAI,UAAU,GAAG,KAAK,CAAC;oBACvB,IAAI,aAAa,KAAK,SAAS,IAAI,aAAa,KAAK,IAAI,EAAE,CAAC;wBAC1D,UAAU,GAAG,KAAK,KAAK,aAAa,CAAC;oBACvC,CAAC;yBAAM,CAAC;wBACN,UAAU,GAAG,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC;oBAC1C,CAAC;oBAED,MAAM,UAAU,GAAG,uBAAuB,CAAC;wBACzC,GAAG,OAAO;wBACV,KAAK;wBACL,QAAQ,EAAE,UAAU;wBACpB,KAAK,EAAE,KAAK;wBACZ,OAAO,EAAE,CAAC,aAAa,EAAE,EAAE;4BACzB,4CAA4C;4BAC5C,UAAU,CAAC,aAAa,CAAC,aAAa,CAAC,CAAC;4BACxC,4BAA4B;4BAC5B,IAAI,OAAO;gCAAE,OAAO,CAAC,aAAa,CAAC,CAAC;wBACtC,CAAC;qBACF,CAAC,CAAC;oBAEH,gBAAgB,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;gBAC3C,CAAC,CAAC,CAAC;YACL,CAAC;QACH,CAAC,CAAC;QAEF,iBAAiB;QACjB,UAAU,EAAE,CAAC;IACf,CAAC;IAED,OAAO,gBAAgB,CAAC;AAC1B,CAAC,CAAC"}
@@ -1,9 +1,9 @@
1
1
  import { type GidsSegmentedTabItemPressedReturnedProps, type GidsSegmentedTabItemCommonProps } from '@ganpatiinfo/gids-core-shared';
2
2
  import { type ClassValue } from '@ganpatiinfo/gids-web-shared';
3
- import { type DomNodeOrString } from '../../utils/domUtils.js';
4
- export interface GidsSegmentedTabItemDomProps extends GidsSegmentedTabItemCommonProps<DomNodeOrString, string> {
3
+ import { DomChildren, type DomNodeOrString } from '../../utils/domUtils.js';
4
+ export interface GidsSegmentedTabItemDomProps extends GidsSegmentedTabItemCommonProps<DomNodeOrString, string, DomChildren> {
5
5
  onPress?: (props: GidsSegmentedTabItemPressedReturnedProps) => void;
6
6
  className?: ClassValue;
7
7
  }
8
- export declare const GidsSegmentedTabItemDom: ({ index, label, selected, badge, badgeAccessibleText, badgeAppearance, onPress, className, width, }: GidsSegmentedTabItemDomProps) => HTMLButtonElement;
8
+ export declare const GidsSegmentedTabItemDom: ({ leadingIcon, trailingIcon, index, label, selected, badge, badgeAccessibleText, badgeAppearance, onPress, className, width, }: GidsSegmentedTabItemDomProps) => HTMLButtonElement;
9
9
  //# sourceMappingURL=GidsSegmentedTabItem.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"GidsSegmentedTabItem.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSegmentedTabItem/GidsSegmentedTabItem.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wCAAwC,EAC7C,KAAK,+BAA+B,EACrC,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,KAAK,UAAU,EAEhB,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAK/D,MAAM,WAAW,4BAA6B,SAAQ,+BAA+B,CACnF,eAAe,EACf,MAAM,CACP;IACC,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,wCAAwC,KAAK,IAAI,CAAC;IACpE,SAAS,CAAC,EAAE,UAAU,CAAC;CACxB;AAED,eAAO,MAAM,uBAAuB,GAAI,qGAUrC,4BAA4B,KAAG,iBA0CjC,CAAC"}
1
+ {"version":3,"file":"GidsSegmentedTabItem.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSegmentedTabItem/GidsSegmentedTabItem.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wCAAwC,EAC7C,KAAK,+BAA+B,EACrC,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,KAAK,UAAU,EAEhB,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAEL,WAAW,EACX,KAAK,eAAe,EACrB,MAAM,yBAAyB,CAAC;AAKjC,MAAM,WAAW,4BAA6B,SAAQ,+BAA+B,CACnF,eAAe,EACf,MAAM,EACN,WAAW,CACZ;IACC,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,wCAAwC,KAAK,IAAI,CAAC;IACpE,SAAS,CAAC,EAAE,UAAU,CAAC;CACxB;AAED,eAAO,MAAM,uBAAuB,GAAI,gIAYrC,4BAA4B,KAAG,iBAwDjC,CAAC"}
@@ -1,8 +1,9 @@
1
1
  import { GidsSegmentedTabItemWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
2
  import clsx from 'clsx';
3
+ import { appendAsChildren, } from '../../utils/domUtils.js';
3
4
  import { GidsBadgeDom } from '../GidsBadge/GidsBadge.js';
4
5
  const { getGidsSegmentedTabItemClassNames } = GidsSegmentedTabItemWebUtils;
5
- export const GidsSegmentedTabItemDom = ({ index, label, selected = false, badge = false, badgeAccessibleText, badgeAppearance = 'information', onPress, className, width = 'intrinsic', }) => {
6
+ export const GidsSegmentedTabItemDom = ({ leadingIcon, trailingIcon, index, label, selected = false, badge = false, badgeAccessibleText, badgeAppearance = 'information', onPress, className, width = 'intrinsic', }) => {
6
7
  const segmentedTabItem = document.createElement('button');
7
8
  segmentedTabItem.className = getGidsSegmentedTabItemClassNames({ selected, width }, className);
8
9
  segmentedTabItem.setAttribute('data-gids-segmented-item', 'true');
@@ -14,6 +15,12 @@ export const GidsSegmentedTabItemDom = ({ index, label, selected = false, badge
14
15
  });
15
16
  }
16
17
  });
18
+ if (leadingIcon) {
19
+ const leadingIconContainer = document.createElement('div');
20
+ leadingIconContainer.className = 'gids-segmented-item__icons';
21
+ appendAsChildren(leadingIconContainer, leadingIcon);
22
+ segmentedTabItem.appendChild(leadingIconContainer);
23
+ }
17
24
  if (label && label !== '') {
18
25
  if (typeof label === 'string') {
19
26
  const labelElement = document.createElement('label');
@@ -27,6 +34,12 @@ export const GidsSegmentedTabItemDom = ({ index, label, selected = false, badge
27
34
  segmentedTabItem.appendChild(label);
28
35
  }
29
36
  }
37
+ if (trailingIcon) {
38
+ const trailingIconContainer = document.createElement('div');
39
+ trailingIconContainer.className = 'gids-segmented-item__selected-icons';
40
+ appendAsChildren(trailingIconContainer, trailingIcon);
41
+ segmentedTabItem.appendChild(trailingIconContainer);
42
+ }
30
43
  if (badge) {
31
44
  segmentedTabItem.appendChild(GidsBadgeDom({
32
45
  accessibleText: badgeAccessibleText,
@@ -1 +1 @@
1
- {"version":3,"file":"GidsSegmentedTabItem.js","sourceRoot":"","sources":["../../../src/components/GidsSegmentedTabItem/GidsSegmentedTabItem.ts"],"names":[],"mappings":"AAIA,OAAO,EAEL,4BAA4B,GAC7B,MAAM,8BAA8B,CAAC;AACtC,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEzD,MAAM,EAAE,iCAAiC,EAAE,GAAG,4BAA4B,CAAC;AAU3E,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,EACtC,KAAK,EACL,KAAK,EACL,QAAQ,GAAG,KAAK,EAChB,KAAK,GAAG,KAAK,EACb,mBAAmB,EACnB,eAAe,GAAG,aAAa,EAC/B,OAAO,EACP,SAAS,EACT,KAAK,GAAG,WAAW,GACU,EAAqB,EAAE;IACpD,MAAM,gBAAgB,GAAG,QAAQ,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC;IAC1D,gBAAgB,CAAC,SAAS,GAAG,iCAAiC,CAC5D,EAAE,QAAQ,EAAE,KAAK,EAAE,EACnB,SAAS,CACV,CAAC;IACF,gBAAgB,CAAC,YAAY,CAAC,0BAA0B,EAAE,MAAM,CAAC,CAAC;IAClE,gBAAgB,CAAC,YAAY,CAAC,eAAe,EAAE,QAAQ,CAAC,QAAQ,EAAE,CAAC,CAAC;IAEpE,gBAAgB,CAAC,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE;QAC9C,IAAI,OAAO,EAAE,CAAC;YACZ,OAAO,CAAC;gBACN,aAAa,EAAE,KAAK;aACrB,CAAC,CAAC;QACL,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,IAAI,KAAK,IAAI,KAAK,KAAK,EAAE,EAAE,CAAC;QAC1B,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC9B,MAAM,YAAY,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;YACrD,YAAY,CAAC,SAAS,GAAG,IAAI,CAAC,gCAAgC,EAAE;gBAC9D,yCAAyC,EAAE,QAAQ;aACpD,CAAC,CAAC;YACH,YAAY,CAAC,WAAW,GAAG,KAAK,CAAC;YACjC,gBAAgB,CAAC,WAAW,CAAC,YAAY,CAAC,CAAC;QAC7C,CAAC;aAAM,CAAC;YACN,gBAAgB,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;QACtC,CAAC;IACH,CAAC;IAED,IAAI,KAAK,EAAE,CAAC;QACV,gBAAgB,CAAC,WAAW,CAC1B,YAAY,CAAC;YACX,cAAc,EAAE,mBAAmB;YACnC,UAAU,EAAE,eAAe;YAC3B,OAAO,EAAE,KAAK;YACd,IAAI,EAAE,KAAK;SACZ,CAAC,CACH,CAAC;IACJ,CAAC;IAED,OAAO,gBAAgB,CAAC;AAC1B,CAAC,CAAC"}
1
+ {"version":3,"file":"GidsSegmentedTabItem.js","sourceRoot":"","sources":["../../../src/components/GidsSegmentedTabItem/GidsSegmentedTabItem.ts"],"names":[],"mappings":"AAIA,OAAO,EAEL,4BAA4B,GAC7B,MAAM,8BAA8B,CAAC;AACtC,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,EACL,gBAAgB,GAGjB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEzD,MAAM,EAAE,iCAAiC,EAAE,GAAG,4BAA4B,CAAC;AAW3E,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,EACtC,WAAW,EACX,YAAY,EACZ,KAAK,EACL,KAAK,EACL,QAAQ,GAAG,KAAK,EAChB,KAAK,GAAG,KAAK,EACb,mBAAmB,EACnB,eAAe,GAAG,aAAa,EAC/B,OAAO,EACP,SAAS,EACT,KAAK,GAAG,WAAW,GACU,EAAqB,E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;IACH,CAAC;IAED,IAAI,YAAY,EAAE,CAAC;QACjB,MAAM,qBAAqB,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QAC5D,qBAAqB,CAAC,SAAS,GAAG,qCAAqC,CAAC;QACxE,gBAAgB,CAAC,qBAAqB,EAAE,YAAY,CAAC,CAAC;QACtD,gBAAgB,CAAC,WAAW,CAAC,qBAAqB,CAAC,CAAC;IACtD,CAAC;IAED,IAAI,KAAK,EAAE,CAAC;QACV,gBAAgB,CAAC,WAAW,CAC1B,YAAY,CAAC;YACX,cAAc,EAAE,mBAAmB;YACnC,UAAU,EAAE,eAAe;YAC3B,OAAO,EAAE,KAAK;YACd,IAAI,EAAE,KAAK;SACZ,CAAC,CACH,CAAC;IACJ,CAAC;IAED,OAAO,gBAAgB,CAAC;AAC1B,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
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSnackbar.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSnackbar/GidsSnackbar.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAEzE,MAAM,MAAM,oBAAoB,GAAG,oBAAoB,CAAC;AAExD,eAAO,MAAM,eAAe,GAAI,kGAS7B,oBAAoB,KAAG,WA0BzB,CAAC"}
@@ -0,0 +1,24 @@
1
+ export const GidsSnackbarDom = ({ message, appearance = 'default', show, onQueueSnackbar, buttonLabel, onButtonClick, position = 'bottom-center', timerInMs, }) => {
2
+ const snackbar = document.createElement('gids-snackbar');
3
+ if (message) {
4
+ snackbar.setAttribute('message', message);
5
+ }
6
+ if (appearance) {
7
+ snackbar.setAttribute('appearance', appearance);
8
+ }
9
+ snackbar.setAttribute('position', position);
10
+ snackbar.setAttribute('timer-in-ms', timerInMs ? `${timerInMs}` : '0');
11
+ snackbar.toggleAttribute('show', show ? show : false);
12
+ if (onQueueSnackbar) {
13
+ snackbar.addEventListener('queueSnackbar', onQueueSnackbar);
14
+ }
15
+ if (buttonLabel) {
16
+ snackbar.setAttribute('button-label', buttonLabel);
17
+ }
18
+ if (onButtonClick) {
19
+ // @ts-expect-error Expected
20
+ snackbar.onButtonClick = onButtonClick;
21
+ }
22
+ return snackbar;
23
+ };
24
+ //# sourceMappingURL=GidsSnackbar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSnackbar.js","sourceRoot":"","sources":["../../../src/components/GidsSnackbar/GidsSnackbar.ts"],"names":[],"mappings":"AAIA,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,EAC9B,OAAO,EACP,UAAU,GAAG,SAAS,EACtB,IAAI,EACJ,eAAe,EACf,WAAW,EACX,aAAa,EACb,QAAQ,GAAG,eAAe,EAC1B,SAAS,GACY,EAAe,EAAE;IACtC,MAAM,QAAQ,GAAG,QAAQ,CAAC,aAAa,CAAC,eAAe,CAAC,CAAC;IAEzD,IAAI,OAAO,EAAE,CAAC;QACZ,QAAQ,CAAC,YAAY,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;IAC5C,CAAC;IACD,IAAI,UAAU,EAAE,CAAC;QACf,QAAQ,CAAC,YAAY,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;IAClD,CAAC;IACD,QAAQ,CAAC,YAAY,CAAC,UAAU,EAAE,QAAQ,CAAC,CAAC;IAC5C,QAAQ,CAAC,YAAY,CAAC,aAAa,EAAE,SAAS,CAAC,CAAC,CAAC,GAAG,SAAS,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IAEvE,QAAQ,CAAC,eAAe,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;IAEtD,IAAI,eAAe,EAAE,CAAC;QACpB,QAAQ,CAAC,gBAAgB,CAAC,eAAe,EAAE,eAAe,CAAC,CAAC;IAC9D,CAAC;IACD,IAAI,WAAW,EAAE,CAAC;QAChB,QAAQ,CAAC,YAAY,CAAC,cAAc,EAAE,WAAW,CAAC,CAAC;IACrD,CAAC;IACD,IAAI,aAAa,EAAE,CAAC;QAClB,4BAA4B;QAC5B,QAAQ,CAAC,aAAa,GAAG,aAAa,CAAC;IACzC,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { type GidsStatusTagCommonProps } from '@ganpatiinfo/gids-core-shared';
2
+ export interface GidsStatusTagDomProps extends GidsStatusTagCommonProps {
3
+ extraClasses?: string;
4
+ }
5
+ export declare const GidsStatusTagDom: (props: GidsStatusTagDomProps) => HTMLDivElement;
6
+ //# sourceMappingURL=GidsStatusTag.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsStatusTag.d.ts","sourceRoot":"","sources":["../../../src/components/GidsStatusTag/GidsStatusTag.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AAQ9E,MAAM,WAAW,qBAAsB,SAAQ,wBAAwB;IACrE,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,gBAAgB,GAC3B,OAAO,qBAAqB,KAC3B,cA4BF,CAAC"}
@@ -0,0 +1,18 @@
1
+ import { GidsStatusTagWebUtils } from '@ganpatiinfo/gids-web-shared';
2
+ import { GidsIconDom } from '../GidsIcon/GidsIcon.js';
3
+ const { getGidsStatusTagClassNames, getStatusTagText, getStatusTagIconName } = GidsStatusTagWebUtils;
4
+ export const GidsStatusTagDom = (props) => {
5
+ const { type = 'new', appearance = 'subtlest', size = 'sm', extraClasses, } = props;
6
+ const statusTag = document.createElement('div');
7
+ statusTag.className = getGidsStatusTagClassNames({ appearance, size, type }, extraClasses);
8
+ const statusTagIconName = getStatusTagIconName(type);
9
+ statusTag.append(GidsIconDom({
10
+ name: statusTagIconName,
11
+ appearance: 'filled',
12
+ }));
13
+ const label = document.createElement('label');
14
+ label.textContent = getStatusTagText(type) ?? '';
15
+ statusTag.appendChild(label);
16
+ return statusTag;
17
+ };
18
+ //# sourceMappingURL=GidsStatusTag.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsStatusTag.js","sourceRoot":"","sources":["../../../src/components/GidsStatusTag/GidsStatusTag.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAGtD,MAAM,EAAE,0BAA0B,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,GAC1E,qBAAqB,CAAC;AAMxB,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAC9B,KAA4B,EACZ,EAAE;IAClB,MAAM,EACJ,IAAI,GAAG,KAAK,EACZ,UAAU,GAAG,UAAU,EACvB,IAAI,GAAG,IAAI,EACX,YAAY,GACb,GAAG,KAAK,CAAC;IAEV,MAAM,SAAS,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IAChD,SAAS,CAAC,SAAS,GAAG,0BAA0B,CAC9C,EAAE,UAAU,EAAE,IAAI,EAAE,IAAI,EAAE,EAC1B,YAAY,CACb,CAAC;IAEF,MAAM,iBAAiB,GAAG,oBAAoB,CAAW,IAAI,CAAC,CAAC;IAC/D,SAAS,CAAC,MAAM,CACd,WAAW,CAAC;QACV,IAAI,EAAE,iBAAiB;QACvB,UAAU,EAAE,QAAQ;KACrB,CAAC,CACH,CAAC;IAEF,MAAM,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;IAC9C,KAAK,CAAC,WAAW,GAAG,gBAAgB,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC;IAEjD,SAAS,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;IAE7B,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { type StepClickProps, type GidsStepperCommonProps } from '@ganpatiinfo/gids-core-shared';
2
+ export interface GidsStepperDomProps extends GidsStepperCommonProps {
3
+ extraClasses?: string;
4
+ onClickMinus?: (params: StepClickProps) => void;
5
+ onClickPlus?: (params: StepClickProps) => void;
6
+ }
7
+ export declare const GidsStepperDom: ({ disabled, extraClasses, onClickMinus, onClickPlus, }: GidsStepperDomProps) => HTMLDivElement;
8
+ //# sourceMappingURL=GidsStepper.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsStepper.d.ts","sourceRoot":"","sources":["../../../src/components/GidsStepper/GidsStepper.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,cAAc,EACnB,KAAK,sBAAsB,EAC5B,MAAM,+BAA+B,CAAC;AAQvC,MAAM,WAAW,mBAAoB,SAAQ,sBAAsB;IACjE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,cAAc,KAAK,IAAI,CAAC;IAChD,WAAW,CAAC,EAAE,CAAC,MAAM,EAAE,cAAc,KAAK,IAAI,CAAC;CAChD;AAED,eAAO,MAAM,cAAc,GAAI,wDAK5B,mBAAmB,KAAG,cAsExB,CAAC"}
@@ -0,0 +1,67 @@
1
+ import { GidsStepperCommonUtils, } from '@ganpatiinfo/gids-core-shared';
2
+ import { GidsStepperWebUtils } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsButtonDom } from '../GidsButton/GidsButton.js';
4
+ import { GidsIconDom } from '../GidsIcon/GidsIcon.js';
5
+ const { isStepperMinusDisabled } = GidsStepperCommonUtils;
6
+ const { getGidsStepperClassNames } = GidsStepperWebUtils;
7
+ export const GidsStepperDom = ({ disabled, extraClasses, onClickMinus, onClickPlus, }) => {
8
+ // 1. Maintain internal state within the closure
9
+ let currentValue = 0;
10
+ const stepper = document.createElement('div');
11
+ stepper.className = getGidsStepperClassNames(extraClasses);
12
+ // 2. Create the display label
13
+ const label = document.createElement('label');
14
+ label.className = `gids-stepper__label ${disabled ? 'gids-stepper__label-disabled' : ''}`;
15
+ // Helper to update the text content
16
+ const updateLabel = () => {
17
+ label.textContent = `${currentValue}`;
18
+ };
19
+ updateLabel();
20
+ // 3. Create the buttons
21
+ const minusButton = GidsButtonDom({
22
+ leadingIcon: GidsIconDom({
23
+ name: 'minus',
24
+ size: 'md',
25
+ appearance: 'regular',
26
+ }),
27
+ disabled: disabled || isStepperMinusDisabled({ stepText: currentValue }),
28
+ size: 'sm',
29
+ width: 'intrinsic',
30
+ appearance: 'default',
31
+ onClick: () => {
32
+ if (disabled)
33
+ return;
34
+ currentValue -= 1;
35
+ updateLabel();
36
+ // Re-evaluate the disabled state of the minus button dynamically
37
+ const isMinusDisabled = disabled || isStepperMinusDisabled({ stepText: currentValue });
38
+ minusButton.toggleAttribute('disabled', isMinusDisabled);
39
+ onClickMinus?.({ stepText: currentValue });
40
+ },
41
+ });
42
+ const plusButton = GidsButtonDom({
43
+ leadingIcon: GidsIconDom({
44
+ name: 'plus',
45
+ size: 'md',
46
+ appearance: 'regular',
47
+ }),
48
+ disabled: disabled,
49
+ size: 'sm',
50
+ width: 'intrinsic',
51
+ appearance: 'default',
52
+ onClick: () => {
53
+ if (disabled)
54
+ return;
55
+ currentValue += 1;
56
+ updateLabel();
57
+ // Ensure the minus button is un-disabled if it was previously locked
58
+ const isMinusDisabled = disabled || isStepperMinusDisabled({ stepText: currentValue });
59
+ minusButton.toggleAttribute('disabled', isMinusDisabled);
60
+ onClickPlus?.({ stepText: currentValue });
61
+ },
62
+ });
63
+ // 4. Assemble the DOM
64
+ stepper.append(minusButton, label, plusButton);
65
+ return stepper;
66
+ };
67
+ //# sourceMappingURL=GidsStepper.js.map
@@ -0,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;IAE/C,OAAO,OAAO,CAAC;AACjB,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { type GidsStrengthMeterCommonProps } from '@ganpatiinfo/gids-core-shared';
2
+ export interface GidsStrengthMeterDomProps extends GidsStrengthMeterCommonProps {
3
+ extraClasses?: string;
4
+ }
5
+ export declare const GidsStrengthMeterDom: ({ text, textMinLength, meterRules, extraClasses, }: GidsStrengthMeterDomProps) => HTMLDivElement;
6
+ //# sourceMappingURL=GidsStrengthMeter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsStrengthMeter.d.ts","sourceRoot":"","sources":["../../../src/components/GidsStrengthMeter/GidsStrengthMeter.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,4BAA4B,EAElC,MAAM,+BAA+B,CAAC;AASvC,MAAM,WAAW,yBAA0B,SAAQ,4BAA4B;IAC7E,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,oBAAoB,GAAI,oDAWlC,yBAAyB,KAAG,cAkD9B,CAAC"}
@@ -0,0 +1,51 @@
1
+ import { GidsStrengthMeterCommonUtils, } from '@ganpatiinfo/gids-core-shared';
2
+ import { GidsStrengthMeterWebUtils } from '@ganpatiinfo/gids-web-shared';
3
+ import { appendAsChildren } from '../../utils/domUtils.js';
4
+ import { minLengthRuleCanBeApplied } from '@ganpatiinfo/gids-core-shared/dist/components/GidsRequirementsMeter/GidsRequirementsMeterCommonUtils.js';
5
+ const { getGidsStrengthMeterClassNames } = GidsStrengthMeterWebUtils;
6
+ const { getStrengthMeterScore, getColorModifierByScore } = GidsStrengthMeterCommonUtils;
7
+ export const GidsStrengthMeterDom = ({ text, textMinLength, meterRules = [
8
+ '1-uppercase',
9
+ '1-lowercase',
10
+ '1-digit',
11
+ '1-special-character',
12
+ 'include-min-length',
13
+ ], extraClasses, }) => {
14
+ const strengthContainer = document.createElement('div');
15
+ strengthContainer.className = getGidsStrengthMeterClassNames(extraClasses);
16
+ const textScore = getStrengthMeterScore({
17
+ text,
18
+ textMinLength,
19
+ meterRules,
20
+ });
21
+ const maxScore = meterRules.length;
22
+ const colorModifier = getColorModifierByScore({ textScore, maxScore });
23
+ const renderStrengthLine = (strengthLine, isActive, index) => {
24
+ // Class construction using the dynamic color modifier for active segments
25
+ strengthLine.className = [
26
+ `gids-strength-meter__strength-${index}`,
27
+ isActive ? 'is-active' : '',
28
+ isActive ? colorModifier : '',
29
+ ]
30
+ .filter(Boolean)
31
+ .join(' ');
32
+ };
33
+ for (let i = 1; i <= maxScore; i++) {
34
+ const strengthLine = document.createElement('div');
35
+ const isActive = i <= textScore;
36
+ if (meterRules[i - 1] === 'include-min-length') {
37
+ if (minLengthRuleCanBeApplied({
38
+ requirementRule: 'include-min-length',
39
+ textMinLength,
40
+ })) {
41
+ renderStrengthLine(strengthLine, isActive, i);
42
+ }
43
+ }
44
+ else {
45
+ renderStrengthLine(strengthLine, isActive, i);
46
+ }
47
+ appendAsChildren(strengthContainer, strengthLine);
48
+ }
49
+ return strengthContainer;
50
+ };
51
+ //# sourceMappingURL=GidsStrengthMeter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsStrengthMeter.js","sourceRoot":"","sources":["../../../src/components/GidsStrengthMeter/GidsStrengthMeter.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,4BAA4B,GAC7B,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,yBAAyB,EAAE,MAAM,8BAA8B,CAAC;AACzE,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,yBAAyB,EAAE,MAAM,yGAAyG,CAAC;AAEpJ,MAAM,EAAE,8BAA8B,EAAE,GAAG,yBAAyB,CAAC;AACrE,MAAM,EAAE,qBAAqB,EAAE,uBAAuB,EAAE,GACtD,4BAA4B,CAAC;AAM/B,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,EACnC,IAAI,EACJ,aAAa,EACb,UAAU,GAAG;IACX,aAA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CAAC,CAAC;YAChD,CAAC;QACH,CAAC;aAAM,CAAC;YACN,kBAAkB,CAAC,YAAY,EAAE,QAAQ,EAAE,CAAC,CAAC,CAAC;QAChD,CAAC;QAED,gBAAgB,CAAC,iBAAiB,EAAE,YAAY,CAAC,CAAC;IACpD,CAAC;IAED,OAAO,iBAAiB,CAAC;AAC3B,CAAC,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { type GidsTextFieldWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { type HtmlInputAttributes } from '../GidsInput/GidsInput.js';
3
+ export interface GidsTextFieldDomProps extends GidsTextFieldWebProps<Element, HtmlInputAttributes> {
4
+ info?: Element;
5
+ className?: string;
6
+ onGidsTextFieldClear?: (event: CustomEvent<void>) => void;
7
+ onChange?: (event: Event) => void;
8
+ onInput?: (event: InputEvent) => void;
9
+ onFocus?: (event: FocusEvent) => void;
10
+ onBlur?: (event: FocusEvent) => void;
11
+ }
12
+ export declare const GidsTextFieldDom: (props: GidsTextFieldDomProps) => HTMLElement;
13
+ //# sourceMappingURL=GidsTextField.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTextField.d.ts","sourceRoot":"","sources":["../../../src/components/GidsTextField/GidsTextField.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AAE1E,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAErE,MAAM,WAAW,qBAAsB,SAAQ,qBAAqB,CAClE,OAAO,EACP,mBAAmB,CACpB;IACC,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,oBAAoB,CAAC,EAAE,CAAC,KAAK,EAAE,WAAW,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC;IAC1D,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,gBAAgB,GAAI,OAAO,qBAAqB,KAAG,WAyC/D,CAAC"}
@@ -0,0 +1,27 @@
1
+ import { assignToSlot } from '../../utils/domUtils.js';
2
+ export const GidsTextFieldDom = (props) => {
3
+ const { info, leadingIcon, trailingIcon, onGidsTextFieldClear, onChange, onInput, onFocus, onBlur, ...restProps } = props;
4
+ const textFieldComponent = document.createElement('gids-text-field');
5
+ Object.assign(textFieldComponent, restProps);
6
+ assignToSlot(textFieldComponent, 'info', info);
7
+ assignToSlot(textFieldComponent, 'leadingIcon', leadingIcon);
8
+ assignToSlot(textFieldComponent, 'trailingIcon', trailingIcon);
9
+ if (onChange) {
10
+ textFieldComponent.addEventListener('change', onChange);
11
+ }
12
+ if (onInput) {
13
+ textFieldComponent.addEventListener('input', onInput);
14
+ }
15
+ if (onFocus) {
16
+ textFieldComponent.addEventListener('focus', onFocus);
17
+ }
18
+ if (onBlur) {
19
+ textFieldComponent.addEventListener('blur', onBlur);
20
+ }
21
+ if (onGidsTextFieldClear) {
22
+ // @ts-expect-error This is a custom event so ts complaining
23
+ textFieldComponent.addEventListener('gidsTextFieldClear', onGidsTextFieldClear);
24
+ }
25
+ return textFieldComponent;
26
+ };
27
+ //# sourceMappingURL=GidsTextField.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTextField.js","sourceRoot":"","sources":["../../../src/components/GidsTextField/GidsTextField.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAgBvD,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,KAA4B,EAAe,EAAE;IAC5E,MAAM,EACJ,IAAI,EACJ,WAAW,EACX,YAAY,EACZ,oBAAoB,EACpB,QAAQ,EACR,OAAO,EACP,OAAO,EACP,MAAM,EACN,GAAG,SAAS,EACb,GAAG,KAAK,CAAC;IAEV,MAAM,kBAAkB,GAAG,QAAQ,CAAC,aAAa,CAAC,iBAAiB,CAAC,CAAC;IACrE,MAAM,CAAC,MAAM,CAAC,kBAAkB,EAAE,SAAS,CAAC,CAAC;IAE7C,YAAY,CAAC,kBAAkB,EAAE,MAAM,EAAE,IAAI,CAAC,CAAC;IAC/C,YAAY,CAAC,kBAAkB,EAAE,aAAa,EAAE,WAAW,CAAC,CAAC;IAC7D,YAAY,CAAC,kBAAkB,EAAE,cAAc,EAAE,YAAY,CAAC,CAAC;IAE/D,IAAI,QAAQ,EAAE,CAAC;QACb,kBAAkB,CAAC,gBAAgB,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;IAC1D,CAAC;IACD,IAAI,OAAO,EAAE,CAAC;QACZ,kBAAkB,CAAC,gBAAgB,CAAC,OAAO,EAAE,OAA6B,CAAC,CAAC;IAC9E,CAAC;IACD,IAAI,OAAO,EAAE,CAAC;QACZ,kBAAkB,CAAC,gBAAgB,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IACxD,CAAC;IACD,IAAI,MAAM,EAAE,CAAC;QACX,kBAAkB,CAAC,gBAAgB,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACtD,CAAC;IACD,IAAI,oBAAoB,EAAE,CAAC;QACzB,4DAA4D;QAC5D,kBAAkB,CAAC,gBAAgB,CACjC,oBAAoB,EACpB,oBAAoB,CACrB,CAAC;IACJ,CAAC;IAED,OAAO,kBAAkB,CAAC;AAC5B,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { type GidsTopNavigationWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { DomChildren, DomNodeOrString } from '../../utils/domUtils.js';
3
+ import { GidsSearchBarDomProps } from '../GidsSearchBar/GidsSearchBar.js';
4
+ import { GidsSegmentedControlDomProps } from '../GidsSegmentedControl/GidsSegmentedControl.js';
5
+ export interface GidsTopNavigationDomProps extends GidsTopNavigationWebProps<DomChildren, DomChildren, DomChildren, DomNodeOrString, string, string, string, DomChildren>, Pick<GidsSearchBarDomProps, 'onBlur' | 'onChange' | 'onFocus' | 'onInput'>, Pick<GidsSegmentedControlDomProps, 'onPress'> {
6
+ extraClasses?: string;
7
+ }
8
+ export declare const GidsTopNavigationDom: (props: GidsTopNavigationDomProps) => HTMLElement;
9
+ //# sourceMappingURL=GidsTopNavigation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTopNavigation.d.ts","sourceRoot":"","sources":["../../../src/components/GidsTopNavigation/GidsTopNavigation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,yBAAyB,EAE/B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAEL,WAAW,EACX,eAAe,EAChB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAEL,qBAAqB,EACtB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAEL,4BAA4B,EAC7B,MAAM,iDAAiD,CAAC;AAKzD,MAAM,WAAW,yBACf,SACE,yBAAyB,CACvB,WAAW,EACX,WAAW,EACX,WAAW,EACX,eAAe,EACf,MAAM,EACN,MAAM,EACN,MAAM,EACN,WAAW,CACZ,EACD,IAAI,CAAC,qBAAqB,EAAE,QAAQ,GAAG,UAAU,GAAG,SAAS,GAAG,SAAS,CAAC,EAC1E,IAAI,CAAC,4BAA4B,EAAE,SAAS,CAAC;IAC/C,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,oBAAoB,GAC/B,OAAO,yBAAyB,KAC/B,WAmFF,CAAC"}
@@ -0,0 +1,61 @@
1
+ import { GidsTopNavigationWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import { appendAsChildren, } from '../../utils/domUtils.js';
3
+ import { GidsSearchBarDom, } from '../GidsSearchBar/GidsSearchBar.js';
4
+ import { GidsSegmentedControlDom, } from '../GidsSegmentedControl/GidsSegmentedControl.js';
5
+ import { GidsLogoDom } from '../GidsLogo/GidsLogo.js';
6
+ const { getGidsTopNavigationClassNames } = GidsTopNavigationWebUtils;
7
+ export const GidsTopNavigationDom = (props) => {
8
+ const { isDefaultLeftContentRender = true, isDefaultMiddleContentRender = true, isDefaultRightContentRender = true, leftContent, middleContent, rightContent, src, imgHeight = '100', href, clickable, onPress, width, tabItems = [], extraClasses, ...rest } = props;
9
+ const topNavigation = document.createElement('nav');
10
+ topNavigation.className = getGidsTopNavigationClassNames(extraClasses);
11
+ const leftContentContainer = document.createElement('div');
12
+ leftContentContainer.className = 'gids-top-navigation__left-content';
13
+ if (leftContent || isDefaultLeftContentRender) {
14
+ if (leftContent) {
15
+ appendAsChildren(leftContentContainer, leftContent);
16
+ }
17
+ if (isDefaultLeftContentRender) {
18
+ leftContentContainer.append(GidsLogoDom({
19
+ src: src,
20
+ imgHeight: imgHeight,
21
+ alt: 'logo-img',
22
+ href: href && href !== '' ? href : '/',
23
+ clickable,
24
+ }));
25
+ }
26
+ topNavigation.appendChild(leftContentContainer);
27
+ }
28
+ const middleContentContainer = document.createElement('div');
29
+ middleContentContainer.className = 'gids-top-navigation__middle-content';
30
+ if (middleContent || isDefaultMiddleContentRender) {
31
+ if (middleContent) {
32
+ appendAsChildren(middleContentContainer, middleContent);
33
+ }
34
+ if (isDefaultMiddleContentRender) {
35
+ middleContentContainer.append(GidsSearchBarDom({
36
+ type: 'default',
37
+ appearance: 'default',
38
+ status: 'default',
39
+ ...rest,
40
+ }));
41
+ }
42
+ topNavigation.appendChild(middleContentContainer);
43
+ }
44
+ const rightContentContainer = document.createElement('div');
45
+ rightContentContainer.className = 'gids-top-navigation__right-content';
46
+ if (rightContent || isDefaultRightContentRender) {
47
+ if (rightContent) {
48
+ appendAsChildren(rightContentContainer, rightContent);
49
+ }
50
+ if (isDefaultRightContentRender) {
51
+ rightContentContainer.append(GidsSegmentedControlDom({
52
+ width: width ? width : 'intrinsic',
53
+ tabItems: tabItems,
54
+ onPress,
55
+ }));
56
+ }
57
+ topNavigation.appendChild(rightContentContainer);
58
+ }
59
+ return topNavigation;
60
+ };
61
+ //# sourceMappingURL=GidsTopNavigation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTopNavigation.js","sourceRoot":"","sources":["../../../src/components/GidsTopNavigation/GidsTopNavigation.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,yBAAyB,GAC1B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EACL,gBAAgB,GAGjB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,gBAAgB,GAEjB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EACL,uBAAuB,GAExB,MAAM,iDAAiD,CAAC;AACzD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAEtD,MAAM,EAAE,8BAA8B,EAAE,GAAG,yBAAyB,CAAC;AAmBrE,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAClC,KAAgC,EACnB,EAAE;IACf,MAAM,EACJ,0BAA0B,GAAG,IAAI,EACjC,4BAA4B,GAAG,IAAI,EACnC,2BAA2B,GAAG,IAAI,EAClC,WAAW,EACX,aAAa,EACb,YAAY,EACZ,GAAG,EACH,SAAS,GAAG,KAAK,EACjB,IAAI,EACJ,SAAS,EACT,OAAO,EACP,KAAK,EACL,QAAQ,GAAG,EAAE,EACb,YAAY,EACZ,GAAG,IAAI,EACR,GAAG,KAAK,CAAC;IAEV,MAAM,aAAa,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IACpD,aAAa,CAAC,SAAS,GAAG,8BAA8B,CAAC,YAAY,CAAC,CAAC;IAEvE,MAAM,oBAAoB,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IAC3D,oBAAoB,CAAC,SAAS,GAAG,mCAAmC,CAAC;IAErE,IAAI,WAAW,IAAI,0BAA0B,EAAE,CAAC;QAC9C,IAAI,WAAW,EAAE,CAAC;YAChB,gBA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BAAqB,CAAC,MAAM,CAC1B,uBAAuB,CAAC;gBACtB,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,WAAW;gBAClC,QAAQ,EAAE,QAAQ;gBAClB,OAAO;aACR,CAAC,CACH,CAAC;QACJ,CAAC;QACD,aAAa,CAAC,WAAW,CAAC,qBAAqB,CAAC,CAAC;IACnD,CAAC;IAED,OAAO,aAAa,CAAC;AACvB,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { GidsNotificationContainerCommonProps } from '@ganpatiinfo/gids-core-shared';
2
+ import { ClassValue } from '@ganpatiinfo/gids-web-shared';
3
+ import { type DomNodeOrString } from '../../utils/domUtils.js';
4
+ export interface GidsNotificationContainerDomProps extends GidsNotificationContainerCommonProps<DomNodeOrString, DomNodeOrString> {
5
+ extraClasses?: ClassValue;
6
+ onCloseNotificationClick?: (this: HTMLButtonElement, event: Event) => void;
7
+ }
8
+ export declare const GidsNotificationContainerDom: (props: GidsNotificationContainerDomProps) => HTMLDivElement;
9
+ //# sourceMappingURL=GidsNotificationContainer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsNotificationContainer.d.ts","sourceRoot":"","sources":["../../../src/components/_GidsNotificationContainer/GidsNotificationContainer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oCAAoC,EAAE,MAAM,+BAA+B,CAAC;AACrF,OAAO,EACL,UAAU,EAEX,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAU/D,MAAM,WAAW,iCAAkC,SAAQ,oCAAoC,CAC7F,eAAe,EACf,eAAe,CAChB;IACC,YAAY,CAAC,EAAE,UAAU,CAAC;IAC1B,wBAAwB,CAAC,EAAE,CAAC,IAAI,EAAE,iBAAiB,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;CAC5E;AAED,eAAO,MAAM,4BAA4B,GACvC,OAAO,iCAAiC,KACvC,cAmGF,CAAC"}