@ganpatiinfo/gids-web-dom-reference 4.0.0 → 6.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 (57) hide show
  1. package/CHANGELOG.md +57 -0
  2. package/dist/components/GidsHeading/GidsHeading.d.ts +2 -2
  3. package/dist/components/GidsHeading/GidsHeading.d.ts.map +1 -1
  4. package/dist/components/GidsHeading/GidsHeading.js +6 -7
  5. package/dist/components/GidsHeading/GidsHeading.js.map +1 -1
  6. package/dist/components/GidsLogo/GidsLogo.d.ts +1 -1
  7. package/dist/components/GidsLogo/GidsLogo.d.ts.map +1 -1
  8. package/dist/components/GidsLogo/GidsLogo.js +5 -2
  9. package/dist/components/GidsLogo/GidsLogo.js.map +1 -1
  10. package/dist/components/GidsScrim/GidsScrim.d.ts +7 -0
  11. package/dist/components/GidsScrim/GidsScrim.d.ts.map +1 -0
  12. package/dist/components/GidsScrim/GidsScrim.js +12 -0
  13. package/dist/components/GidsScrim/GidsScrim.js.map +1 -0
  14. package/dist/components/GidsSegmentedControl/GidsSegmentedControl.d.ts +3 -3
  15. package/dist/components/GidsSegmentedControl/GidsSegmentedControl.d.ts.map +1 -1
  16. package/dist/components/GidsSegmentedControl/GidsSegmentedControl.js +2 -2
  17. package/dist/components/GidsSegmentedControl/GidsSegmentedControl.js.map +1 -1
  18. package/dist/components/GidsSegmentedTabItem/GidsSegmentedTabItem.d.ts +3 -3
  19. package/dist/components/GidsSegmentedTabItem/GidsSegmentedTabItem.d.ts.map +1 -1
  20. package/dist/components/GidsSegmentedTabItem/GidsSegmentedTabItem.js +24 -2
  21. package/dist/components/GidsSegmentedTabItem/GidsSegmentedTabItem.js.map +1 -1
  22. package/dist/components/GidsSideMenu/GidsSideMenu.d.ts +7 -0
  23. package/dist/components/GidsSideMenu/GidsSideMenu.d.ts.map +1 -0
  24. package/dist/components/GidsSideMenu/GidsSideMenu.js +13 -0
  25. package/dist/components/GidsSideMenu/GidsSideMenu.js.map +1 -0
  26. package/dist/components/GidsSideMenuHeader/GidsSideMenuHeader.d.ts +9 -0
  27. package/dist/components/GidsSideMenuHeader/GidsSideMenuHeader.d.ts.map +1 -0
  28. package/dist/components/GidsSideMenuHeader/GidsSideMenuHeader.js +29 -0
  29. package/dist/components/GidsSideMenuHeader/GidsSideMenuHeader.js.map +1 -0
  30. package/dist/components/GidsSideMenuItem/GidsSideMenuItem.d.ts +8 -0
  31. package/dist/components/GidsSideMenuItem/GidsSideMenuItem.d.ts.map +1 -0
  32. package/dist/components/GidsSideMenuItem/GidsSideMenuItem.js +62 -0
  33. package/dist/components/GidsSideMenuItem/GidsSideMenuItem.js.map +1 -0
  34. package/dist/components/GidsSideNavigation/GidsSideNavigation.d.ts +9 -0
  35. package/dist/components/GidsSideNavigation/GidsSideNavigation.d.ts.map +1 -0
  36. package/dist/components/GidsSideNavigation/GidsSideNavigation.js +36 -0
  37. package/dist/components/GidsSideNavigation/GidsSideNavigation.js.map +1 -0
  38. package/dist/components/GidsTopNavigation/GidsTopNavigation.d.ts +1 -1
  39. package/dist/components/GidsTopNavigation/GidsTopNavigation.d.ts.map +1 -1
  40. package/dist/components/GidsTopNavigation/GidsTopNavigation.js +17 -5
  41. package/dist/components/GidsTopNavigation/GidsTopNavigation.js.map +1 -1
  42. package/dist/index.d.ts +5 -0
  43. package/dist/index.d.ts.map +1 -1
  44. package/dist/index.js +5 -0
  45. package/dist/index.js.map +1 -1
  46. package/package.json +3 -3
  47. package/src/components/GidsHeading/GidsHeading.ts +13 -6
  48. package/src/components/GidsLogo/GidsLogo.ts +6 -0
  49. package/src/components/GidsScrim/GidsScrim.ts +25 -0
  50. package/src/components/GidsSegmentedControl/GidsSegmentedControl.ts +5 -3
  51. package/src/components/GidsSegmentedTabItem/GidsSegmentedTabItem.ts +37 -3
  52. package/src/components/GidsSideMenu/GidsSideMenu.ts +31 -0
  53. package/src/components/GidsSideMenuHeader/GidsSideMenuHeader.ts +71 -0
  54. package/src/components/GidsSideMenuItem/GidsSideMenuItem.ts +108 -0
  55. package/src/components/GidsSideNavigation/GidsSideNavigation.ts +97 -0
  56. package/src/components/GidsTopNavigation/GidsTopNavigation.ts +28 -5
  57. package/src/index.ts +5 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,62 @@
1
1
  # @ganpatiinfo/gids-web-dom-reference
2
2
 
3
+ ## 6.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - fba5d5d: Developed `GidsSideMenu` private component for react and html core web platforms
8
+ - 8f1220b: Developed `GidsSideMenuHeader` private component for react and html core web platforms
9
+ - 482b769: - Developed `GidsSideNavigation` component for react and html core web platforms
10
+
11
+ ### Minor Changes
12
+
13
+ - 482b769: - Updated `GidsSidemuItem` component in all web platforms
14
+ - 9caf527: - Updated `GidsTopNavigation` component in all web platforms
15
+ - 482b769: - Updated `GidsSideMenuHeader` in all web platforms
16
+ - 9caf527: - Fixed a coloring issue in `GidsInputTag` component in all web platforms
17
+ - e505944: Updated `GidsLogo` component in all web platforms
18
+ - e505944: Updated `GidsTopNavigation` component in all web platforms
19
+ - 482b769: - Updated `GidsSideMenu` in all web platforms
20
+ - 9caf527: - Updated `GidsSegmentedControl` component in all web platforms
21
+
22
+ ### Patch Changes
23
+
24
+ - Updated dependencies [fba5d5d]
25
+ - Updated dependencies [482b769]
26
+ - Updated dependencies [9caf527]
27
+ - Updated dependencies [482b769]
28
+ - Updated dependencies [e505944]
29
+ - Updated dependencies [e505944]
30
+ - Updated dependencies [482b769]
31
+ - Updated dependencies [8f1220b]
32
+ - Updated dependencies [482b769]
33
+ - Updated dependencies [9caf527]
34
+ - @ganpatiinfo/gids-core-shared@6.0.0
35
+ - @ganpatiinfo/gids-web-shared@6.0.0
36
+
37
+ ## 5.0.0
38
+
39
+ ### Major Changes
40
+
41
+ - e6382f1: Developed `GidsSideMenuItem` private component for all web platforms
42
+ - 3ec3507: Developed `GidsScrim` component for all web platforms
43
+
44
+ ### Minor Changes
45
+
46
+ - 74ea6bd: - Updated `GidsSegmentedTabItem` component for all web platforms.
47
+ - 74ea6bd: - Updated `GidsTopNavigation` component for all web platforms.
48
+ - 74ea6bd: - Updated `GidsSegmentedControl` component for all web platforms.
49
+
50
+ ### Patch Changes
51
+
52
+ - Updated dependencies [74ea6bd]
53
+ - Updated dependencies [e6382f1]
54
+ - Updated dependencies [3ec3507]
55
+ - Updated dependencies [74ea6bd]
56
+ - Updated dependencies [74ea6bd]
57
+ - @ganpatiinfo/gids-core-shared@5.0.0
58
+ - @ganpatiinfo/gids-web-shared@5.0.0
59
+
3
60
  ## 4.0.0
4
61
 
5
62
  ### Major Changes
@@ -1,6 +1,6 @@
1
- import { GidsHeadingCommonProps } from '@ganpatiinfo/gids-core-shared';
1
+ import { type GidsHeadingWebProps } from '@ganpatiinfo/gids-web-shared';
2
2
  import { DomChildren, DomNodeOrString } from '../../utils/domUtils.js';
3
- export interface GidsHeadingDomProps extends GidsHeadingCommonProps<DomChildren, DomNodeOrString> {
3
+ export interface GidsHeadingDomProps extends GidsHeadingWebProps<DomChildren, DomNodeOrString> {
4
4
  extraClasses?: string;
5
5
  }
6
6
  export declare const GidsHeadingDom: (props: GidsHeadingDomProps) => HTMLDivElement;
@@ -1 +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"}
1
+ {"version":3,"file":"GidsHeading.d.ts","sourceRoot":"","sources":["../../../src/components/GidsHeading/GidsHeading.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,mBAAmB,EAEzB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAEL,WAAW,EACX,eAAe,EAChB,MAAM,yBAAyB,CAAC;AAQjC,MAAM,WAAW,mBAAoB,SAAQ,mBAAmB,CAC9D,WAAW,EACX,eAAe,CAChB;IACC,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,cAAc,GAAI,OAAO,mBAAmB,KAAG,cAuD3D,CAAC"}
@@ -1,9 +1,9 @@
1
- import { GidsHeadingWebUtils } from '@ganpatiinfo/gids-web-shared';
1
+ import { GidsHeadingWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
2
  import { appendAsChildren, } from '../../utils/domUtils.js';
3
3
  import { GidsButtonGroupDom } from '../GidsButtonGroup/GidsButtonGroup.js';
4
- const { getGidsHeadingClassNames } = GidsHeadingWebUtils;
4
+ const { getGidsHeadingClassNames, getGidsHeadingSupportingTextTypographyClass, } = GidsHeadingWebUtils;
5
5
  export const GidsHeadingDom = (props) => {
6
- const { heading, supportingText, level = 'section', children, extraClasses, } = props;
6
+ const { heading, supportingText, supportingTextTypography, level = 'section', children, extraClasses, } = props;
7
7
  const headingContainer = document.createElement('div');
8
8
  headingContainer.className = getGidsHeadingClassNames(extraClasses);
9
9
  const contentContainer = document.createElement('div');
@@ -25,10 +25,9 @@ export const GidsHeadingDom = (props) => {
25
25
  if (supportingText) {
26
26
  if (typeof supportingText === 'string') {
27
27
  const supportingTextEl = document.createElement('span');
28
- supportingTextEl.className =
29
- level === 'section'
30
- ? 'gids-heading__supporting-text-section'
31
- : 'gids-heading__supporting-text-group';
28
+ supportingTextEl.className = `${level === 'section'
29
+ ? 'gids-heading__supporting-text-section'
30
+ : 'gids-heading__supporting-text-group'} ${getGidsHeadingSupportingTextTypographyClass(supportingTextTypography)}`;
32
31
  supportingTextEl.textContent = supportingText;
33
32
  appendAsChildren(contentContainer, supportingTextEl);
34
33
  }
@@ -1 +1 @@
1
- {"version":3,"file":"G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ACrB,kBAAkB,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAC3D,CAAC;IACJ,CAAC;IAED,OAAO,gBAAgB,CAAC;AAC1B,CAAC,CAAC"}
@@ -4,5 +4,5 @@ export interface GidsLogoDomProps extends GidsLogoWebProps<string, string>, Omit
4
4
  imgClasses?: ClassValue;
5
5
  imgProps?: Omit<Partial<HTMLImageElement>, 'src' | 'alt' | 'class' | 'height'>;
6
6
  }
7
- export declare const GidsLogoDom: ({ src, href, alt, clickable, extraClasses, imgClasses, imgProps, imgHeight, ...restProps }: GidsLogoDomProps) => HTMLAnchorElement;
7
+ export declare const GidsLogoDom: ({ src, href, alt, clickable, extraClasses, imgClasses, imgProps, imgHeight, invertedInDarkMode, invertedInLightMode, ...restProps }: GidsLogoDomProps) => HTMLAnchorElement;
8
8
  //# sourceMappingURL=GidsLogo.d.ts.map
@@ -1 +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"}
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,qIAYzB,gBAAgB,KAAG,iBAgCrB,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import { GidsLogoWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
2
  import clsx from 'clsx';
3
3
  const { getGidsLogoClassNames } = GidsLogoWebUtils;
4
- export const GidsLogoDom = ({ src, href, alt, clickable, extraClasses, imgClasses, imgProps, imgHeight = '100', ...restProps }) => {
4
+ export const GidsLogoDom = ({ src, href, alt, clickable, extraClasses, imgClasses, imgProps, imgHeight = '100', invertedInDarkMode, invertedInLightMode, ...restProps }) => {
5
5
  const linkElement = document.createElement('a');
6
6
  linkElement.className = getGidsLogoClassNames(extraClasses);
7
7
  if (restProps) {
@@ -12,7 +12,10 @@ export const GidsLogoDom = ({ src, href, alt, clickable, extraClasses, imgClasse
12
12
  }
13
13
  if (src && src !== '') {
14
14
  const imgElement = document.createElement('img');
15
- imgElement.className = clsx(`gids-logo__img gids-logo__img-height-${imgHeight}`, imgClasses);
15
+ imgElement.className = clsx(`gids-logo__img gids-logo__img-height-${imgHeight}`, {
16
+ 'gids-logo__inverted-img-in-dark': invertedInDarkMode,
17
+ 'gids-logo__inverted-img-in-light': invertedInLightMode,
18
+ }, imgClasses);
16
19
  imgElement.setAttribute('src', src);
17
20
  imgElement.setAttribute('alt', alt ? alt : 'logo');
18
21
  if (imgProps) {
@@ -1 +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,C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BAAkB;YACrD,kCAAkC,EAAE,mBAAmB;SACxD,EACD,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,7 @@
1
+ import { type GidsScrimWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { type DomChildren } from '../../utils/domUtils.js';
3
+ export interface GidsScrimDomProps extends GidsScrimWebProps<DomChildren> {
4
+ extraClasses?: string;
5
+ }
6
+ export declare const GidsScrimDom: ({ children, extraClasses, }: GidsScrimDomProps) => HTMLElement;
7
+ //# sourceMappingURL=GidsScrim.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsScrim.d.ts","sourceRoot":"","sources":["../../../src/components/GidsScrim/GidsScrim.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,iBAAiB,EAEvB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAoB,KAAK,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAI7E,MAAM,WAAW,iBAAkB,SAAQ,iBAAiB,CAAC,WAAW,CAAC;IACvE,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,YAAY,GAAI,6BAG1B,iBAAiB,KAAG,WAStB,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { GidsScrimWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import { appendAsChildren } from '../../utils/domUtils.js';
3
+ const { getGidsScrimClassNames } = GidsScrimWebUtils;
4
+ export const GidsScrimDom = ({ children, extraClasses, }) => {
5
+ const scrimEl = document.createElement('gids-scrim');
6
+ scrimEl.className = getGidsScrimClassNames(extraClasses);
7
+ if (children) {
8
+ appendAsChildren(scrimEl, children);
9
+ }
10
+ return scrimEl;
11
+ };
12
+ //# sourceMappingURL=GidsScrim.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsScrim.js","sourceRoot":"","sources":["../../../src/components/GidsScrim/GidsScrim.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,iBAAiB,GAClB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,gBAAgB,EAAoB,MAAM,yBAAyB,CAAC;AAE7E,MAAM,EAAE,sBAAsB,EAAE,GAAG,iBAAiB,CAAC;AAMrD,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,EAC3B,QAAQ,EACR,YAAY,GACM,EAAe,EAAE;IACnC,MAAM,OAAO,GAAG,QAAQ,CAAC,aAAa,CAAC,YAAY,CAAC,CAAC;IACrD,OAAO,CAAC,SAAS,GAAG,sBAAsB,CAAC,YAAY,CAAC,CAAC;IAEzD,IAAI,QAAQ,EAAE,CAAC;QACb,gBAAgB,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC;IACtC,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC,CAAC"}
@@ -1,9 +1,9 @@
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
  }
8
- export declare const GidsSegmentedControlDom: ({ width, tabItems, onPress, className, }: GidsSegmentedControlDomProps) => HTMLDivElement;
8
+ export declare const GidsSegmentedControlDom: ({ width, tabItems, onPress, className, defaultSelectedIndex, }: GidsSegmentedControlDomProps) => HTMLDivElement;
9
9
  //# sourceMappingURL=GidsSegmentedControl.d.ts.map
@@ -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,gEAMrC,4BAA4B,KAAG,cAgDjC,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import { GidsSegmentedControlWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
2
  import { GidsSegmentedTabItemDom } from '../GidsSegmentedTabItem/GidsSegmentedTabItem.js';
3
3
  const { getGidsSegmentedControlClassNames } = GidsSegmentedControlWebUtils;
4
- export const GidsSegmentedControlDom = ({ width = 'intrinsic', tabItems, onPress, className, }) => {
4
+ export const GidsSegmentedControlDom = ({ width = 'intrinsic', tabItems, onPress, className, defaultSelectedIndex, }) => {
5
5
  const segmentedControl = document.createElement('div');
6
6
  segmentedControl.className = getGidsSegmentedControlClassNames({ width }, className);
7
7
  if (tabItems && tabItems.length > 0) {
@@ -13,7 +13,7 @@ export const GidsSegmentedControlDom = ({ width = 'intrinsic', tabItems, onPress
13
13
  tabItems.forEach((tabItem, index) => {
14
14
  // Determine if this tab is selected
15
15
  // Priority: 1. The newly clicked index, 2. The initial tabItem.selected state
16
- let isSelected = false;
16
+ let isSelected = defaultSelectedIndex === index;
17
17
  if (selectedIndex !== undefined && selectedIndex !== null) {
18
18
  isSelected = index === selectedIndex;
19
19
  }
@@ -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;AAU3E,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,EACtC,KAAK,GAAG,WAAW,EACnB,QAAQ,EACR,OAAO,EACP,SAAS,GACoB,EAAkB,EAAE;IACjD,MAAM,gBAAgB,GAAG,QA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AC,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,iBAqEjC,CAAC"}
@@ -1,10 +1,16 @@
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
- segmentedTabItem.className = getGidsSegmentedTabItemClassNames({ selected, width }, className);
8
+ let isIconOnly = false;
9
+ if ((leadingIcon && !trailingIcon && (!label || label === '') && !badge) ||
10
+ (!leadingIcon && trailingIcon && (!label || label === '') && !badge)) {
11
+ isIconOnly = true;
12
+ }
13
+ segmentedTabItem.className = getGidsSegmentedTabItemClassNames({ selected, width, isIconOnly }, className);
8
14
  segmentedTabItem.setAttribute('data-gids-segmented-item', 'true');
9
15
  segmentedTabItem.setAttribute('aria-selected', selected.toString());
10
16
  segmentedTabItem.addEventListener('click', () => {
@@ -14,6 +20,14 @@ export const GidsSegmentedTabItemDom = ({ index, label, selected = false, badge
14
20
  });
15
21
  }
16
22
  });
23
+ if (leadingIcon) {
24
+ const leadingIconContainer = document.createElement('div');
25
+ leadingIconContainer.className = clsx('gids-segmented-tab-item__icons', {
26
+ 'gids-segmented-tab-item__selected-icons': selected,
27
+ });
28
+ appendAsChildren(leadingIconContainer, leadingIcon);
29
+ segmentedTabItem.appendChild(leadingIconContainer);
30
+ }
17
31
  if (label && label !== '') {
18
32
  if (typeof label === 'string') {
19
33
  const labelElement = document.createElement('label');
@@ -27,6 +41,14 @@ export const GidsSegmentedTabItemDom = ({ index, label, selected = false, badge
27
41
  segmentedTabItem.appendChild(label);
28
42
  }
29
43
  }
44
+ if (trailingIcon) {
45
+ const trailingIconContainer = document.createElement('div');
46
+ trailingIconContainer.className = clsx('gids-segmented-tab-item__icons', {
47
+ 'gids-segmented-tab-item__selected-icons': selected,
48
+ });
49
+ appendAsChildren(trailingIconContainer, trailingIcon);
50
+ segmentedTabItem.appendChild(trailingIconContainer);
51
+ }
30
52
  if (badge) {
31
53
  segmentedTabItem.appendChild(GidsBadgeDom({
32
54
  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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{ GidsSideMenuWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { DomChildren } from '../../utils/domUtils.js';
3
+ export interface GidsSideMenuDomProps extends GidsSideMenuWebProps<DomChildren> {
4
+ sideMenuExtraClasses?: string;
5
+ }
6
+ export declare const GidsSideMenuDom: ({ children, sideMenuAppearance, sideMenuExtraClasses, }: GidsSideMenuDomProps) => HTMLDivElement;
7
+ //# sourceMappingURL=GidsSideMenu.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSideMenu.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSideMenu/GidsSideMenu.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,EAErB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAoB,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAIxE,MAAM,WAAW,oBAAqB,SAAQ,oBAAoB,CAAC,WAAW,CAAC;IAC7E,oBAAoB,CAAC,EAAE,MAAM,CAAC;CAC/B;AAED,eAAO,MAAM,eAAe,GAAI,yDAI7B,oBAAoB,KAAG,cAczB,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { GidsSideMenuWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import { appendAsChildren } from '../../utils/domUtils.js';
3
+ const { getGidsSideMenuClassNames } = GidsSideMenuWebUtils;
4
+ export const GidsSideMenuDom = ({ children, sideMenuAppearance = 'default', sideMenuExtraClasses, }) => {
5
+ const sideMenu = document.createElement('div');
6
+ sideMenu.className = getGidsSideMenuClassNames({ sideMenuAppearance }, sideMenuExtraClasses);
7
+ sideMenu.setAttribute('side-menu-appearance', sideMenuAppearance);
8
+ if (children) {
9
+ appendAsChildren(sideMenu, children);
10
+ }
11
+ return sideMenu;
12
+ };
13
+ //# sourceMappingURL=GidsSideMenu.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSideMenu.js","sourceRoot":"","sources":["../../../src/components/GidsSideMenu/GidsSideMenu.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,oBAAoB,GACrB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,gBAAgB,EAAe,MAAM,yBAAyB,CAAC;AAExE,MAAM,EAAE,yBAAyB,EAAE,GAAG,oBAAoB,CAAC;AAM3D,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,EAC9B,QAAQ,EACR,kBAAkB,GAAG,SAAS,EAC9B,oBAAoB,GACC,EAAkB,EAAE;IACzC,MAAM,QAAQ,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IAC/C,QAAQ,CAAC,SAAS,GAAG,yBAAyB,CAC5C,EAAE,kBAAkB,EAAE,EACtB,oBAAoB,CACrB,CAAC;IAEF,QAAQ,CAAC,YAAY,CAAC,sBAAsB,EAAE,kBAAkB,CAAC,CAAC;IAElE,IAAI,QAAQ,EAAE,CAAC;QACb,gBAAgB,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;IACvC,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { GidsSideMenuHeaderWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { type HtmlInputAttributes } from '../GidsInput/GidsInput.js';
3
+ import { GidsSearchBarDomProps } from '../GidsSearchBar/GidsSearchBar.js';
4
+ import { DomChildren } from '../../utils/domUtils.js';
5
+ export interface GidsSideMenuHeaderDomProps extends GidsSideMenuHeaderWebProps<DomChildren, Element, HtmlInputAttributes>, Pick<GidsSearchBarDomProps, 'wrapperClass' | 'onGidsSearchBarClear' | 'className' | 'onBlur' | 'onChange' | 'onFocus' | 'onInput'> {
6
+ headerClasses?: string;
7
+ }
8
+ export declare const GidsSideMenuHeaderDom: ({ headerAppearance, headerDividedByDivider, customChildren, searchVisible, onGidsSearchBarClear, headerClasses, ...restProps }: GidsSideMenuHeaderDomProps) => HTMLDivElement;
9
+ //# sourceMappingURL=GidsSideMenuHeader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSideMenuHeader.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSideMenuHeader/GidsSideMenuHeader.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,0BAA0B,EAE3B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AACrE,OAAO,EAEL,qBAAqB,EACtB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAoB,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAKxE,MAAM,WAAW,0BACf,SACE,0BAA0B,CAAC,WAAW,EAAE,OAAO,EAAE,mBAAmB,CAAC,EACrE,IAAI,CACF,qBAAqB,EACnB,cAAc,GACd,sBAAsB,GACtB,WAAW,GACX,QAAQ,GACR,UAAU,GACV,SAAS,GACT,SAAS,CACZ;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,eAAO,MAAM,qBAAqB,GAAI,gIAQnC,0BAA0B,mBAgC5B,CAAC"}
@@ -0,0 +1,29 @@
1
+ import { GidsSideMenuHeaderWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import { GidsSearchBarDom, } from '../GidsSearchBar/GidsSearchBar.js';
3
+ import { appendAsChildren } from '../../utils/domUtils.js';
4
+ import { GidsDividerDom } from '../GidsDivider/GidsDivider.js';
5
+ const { getGidsSideMenuHeaderClassNames } = GidsSideMenuHeaderWebUtils;
6
+ export const GidsSideMenuHeaderDom = ({ headerAppearance, headerDividedByDivider = true, customChildren, searchVisible = true, onGidsSearchBarClear, headerClasses, ...restProps }) => {
7
+ const sideMenuHeader = document.createElement('div');
8
+ sideMenuHeader.className = getGidsSideMenuHeaderClassNames({ headerAppearance }, headerClasses);
9
+ const sideMenuContentWrapper = document.createElement('div');
10
+ sideMenuContentWrapper.className = 'gids-side-menu-header__content-wrapper';
11
+ if (customChildren) {
12
+ appendAsChildren(sideMenuContentWrapper, customChildren);
13
+ }
14
+ if (searchVisible) {
15
+ const searchBarEl = document.createElement('div');
16
+ searchBarEl.className = 'gids-side-menu-header__search-bar';
17
+ searchBarEl.append(GidsSearchBarDom({
18
+ ...restProps,
19
+ onGidsSearchBarClear: onGidsSearchBarClear,
20
+ }));
21
+ sideMenuContentWrapper.appendChild(searchBarEl);
22
+ }
23
+ sideMenuHeader.appendChild(sideMenuContentWrapper);
24
+ if (headerDividedByDivider) {
25
+ sideMenuHeader.append(GidsDividerDom({ orientation: 'horizontal' }));
26
+ }
27
+ return sideMenuHeader;
28
+ };
29
+ //# sourceMappingURL=GidsSideMenuHeader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSideMenuHeader.js","sourceRoot":"","sources":["../../../src/components/GidsSideMenuHeader/GidsSideMenuHeader.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,0BAA0B,GAC3B,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EACL,gBAAgB,GAEjB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,gBAAgB,EAAe,MAAM,yBAAyB,CAAC;AACxE,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAE/D,MAAM,EAAE,+BAA+B,EAAE,GAAG,0BAA0B,CAAC;AAkBvE,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,EACpC,gBAAgB,EAChB,sBAAsB,GAAG,IAAI,EAC7B,cAAc,EACd,aAAa,GAAG,IAAI,EACpB,oBAAoB,EACpB,aAAa,EACb,GAAG,SAAS,EACe,EAAE,EAAE;IAC/B,MAAM,cAAc,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IACrD,cAAc,CAAC,SAAS,GAAG,+BAA+B,CACxD,EAAE,gBAAgB,EAAE,EACpB,aAAa,CACd,CAAC;IAEF,MAAM,sBAAsB,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IAC7D,sBAAsB,CAAC,SAAS,GAAG,wCAAwC,CAAC;IAE5E,IAAI,cAAc,EAAE,CAAC;QACnB,gBAAgB,CAAC,sBAAsB,EAAE,cAAc,CAAC,CAAC;IAC3D,CAAC;IAED,IAAI,aAAa,EAAE,CAAC;QAClB,MAAM,WAAW,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QAClD,WAAW,CAAC,SAAS,GAAG,mCAAmC,CAAC;QAC5D,WAAW,CAAC,MAAM,CAChB,gBAAgB,CAAC;YACf,GAAG,SAAS;YACZ,oBAAoB,EAAE,oBAAoB;SAC3C,CAAC,CACH,CAAC;QACF,sBAAsB,CAAC,WAAW,CAAC,WAAW,CAAC,CAAC;IAClD,CAAC;IACD,cAAc,CAAC,WAAW,CAAC,sBAAsB,CAAC,CAAC;IAEnD,IAAI,sBAAsB,EAAE,CAAC;QAC3B,cAAc,CAAC,MAAM,CAAC,cAAc,CAAC,EAAE,WAAW,EAAE,YAAY,EAAE,CAAC,CAAC,CAAC;IACvE,CAAC;IAED,OAAO,cAAc,CAAC;AACxB,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { type GidsSideMenuItemOnPressEvent, type GidsSideMenuItemWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { DomChildren, DomNodeOrString } from '../../utils/domUtils.js';
3
+ export interface GidsSideMenuItemDomProps extends GidsSideMenuItemWebProps<DomNodeOrString, DomChildren, DomChildren> {
4
+ extraClasses?: string;
5
+ onPressSideMenuItem?: GidsSideMenuItemOnPressEvent;
6
+ }
7
+ export declare const GidsSideMenuItemDom: ({ appearance, index, selected, isLeadingDotVisible, leadingDotAppearance, leadingAccessory, trailingAccessory, leadingIcon, trailingIcon, isTrailingArrowVisible, trailingArrowDirection, children, extraClasses, onPressSideMenuItem, }: GidsSideMenuItemDomProps) => HTMLDivElement;
8
+ //# sourceMappingURL=GidsSideMenuItem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSideMenuItem.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSideMenuItem/GidsSideMenuItem.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,4BAA4B,EACjC,KAAK,wBAAwB,EAE9B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAEL,WAAW,EACX,eAAe,EAChB,MAAM,yBAAyB,CAAC;AASjC,MAAM,WAAW,wBAAyB,SAAQ,wBAAwB,CACxE,eAAe,EACf,WAAW,EACX,WAAW,CACZ;IACC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mBAAmB,CAAC,EAAE,4BAA4B,CAAC;CACpD;AAED,eAAO,MAAM,mBAAmB,GAAI,0OAejC,wBAAwB,KAAG,cAiE7B,CAAC"}
@@ -0,0 +1,62 @@
1
+ import { GidsSideMenuItemWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import { appendAsChildren, } from '../../utils/domUtils.js';
3
+ import { GidsBadgeDom } from '../GidsBadge/GidsBadge.js';
4
+ import { GidsIconDom } from '../GidsIcon/GidsIcon.js';
5
+ import { GidsSideMenuItemCommonUtils } from '@ganpatiinfo/gids-core-shared';
6
+ const { getGidsSideMenuItemClassNames } = GidsSideMenuItemWebUtils;
7
+ const { getSideMenuTrailingIcon } = GidsSideMenuItemCommonUtils;
8
+ export const GidsSideMenuItemDom = ({ appearance = 'default', index = 0, selected, isLeadingDotVisible = false, leadingDotAppearance = 'information', leadingAccessory, trailingAccessory, leadingIcon, trailingIcon, isTrailingArrowVisible = false, trailingArrowDirection = 'right', children, extraClasses, onPressSideMenuItem, }) => {
9
+ const sideMenuItem = document.createElement('div');
10
+ sideMenuItem.className = getGidsSideMenuItemClassNames({ selected, appearance }, extraClasses);
11
+ sideMenuItem.setAttribute('index', `${index}`);
12
+ if (leadingAccessory) {
13
+ appendAsChildren(sideMenuItem, leadingAccessory);
14
+ }
15
+ else {
16
+ if (isLeadingDotVisible) {
17
+ sideMenuItem.append(GidsBadgeDom({
18
+ appearance: leadingDotAppearance,
19
+ type: 'dot',
20
+ }));
21
+ }
22
+ }
23
+ if (leadingIcon) {
24
+ appendAsChildren(sideMenuItem, leadingIcon);
25
+ }
26
+ if (children) {
27
+ const textEl = document.createElement('span');
28
+ textEl.className = 'gids-side-menu-item__label';
29
+ if (typeof children === 'string') {
30
+ textEl.textContent = children;
31
+ }
32
+ else {
33
+ textEl.appendChild(children);
34
+ }
35
+ appendAsChildren(sideMenuItem, textEl);
36
+ }
37
+ if (trailingAccessory) {
38
+ appendAsChildren(sideMenuItem, trailingAccessory);
39
+ }
40
+ if (trailingIcon) {
41
+ appendAsChildren(sideMenuItem, trailingIcon);
42
+ }
43
+ else {
44
+ if (isTrailingArrowVisible) {
45
+ sideMenuItem.append(GidsIconDom({
46
+ name: getSideMenuTrailingIcon(trailingArrowDirection),
47
+ size: 'md',
48
+ alt: '',
49
+ appearance: 'regular',
50
+ }));
51
+ }
52
+ }
53
+ if (onPressSideMenuItem) {
54
+ sideMenuItem.addEventListener('click', () => {
55
+ onPressSideMenuItem({
56
+ selectedIndex: index,
57
+ });
58
+ });
59
+ }
60
+ return sideMenuItem;
61
+ };
62
+ //# sourceMappingURL=GidsSideMenuItem.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSideMenuItem.js","sourceRoot":"","sources":["../../../src/components/GidsSideMenuItem/GidsSideMenuItem.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,wBAAwB,GACzB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EACL,gBAAgB,GAGjB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,2BAA2B,EAAE,MAAM,+BAA+B,CAAC;AAG5E,MAAM,EAAE,6BAA6B,EAAE,GAAG,wBAAwB,CAAC;AACnE,MAAM,EAAE,uBAAuB,EAAE,GAAG,2BAA2B,CAAC;AAWhE,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,EAClC,UAAU,GAAG,SAAS,EACtB,KAAK,GAAG,CAAC,EACT,QAA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B,EAAE,CAAC;QACtB,gBAAgB,CAAC,YAAY,EAAE,iBAAiB,CAAC,CAAC;IACpD,CAAC;IAED,IAAI,YAAY,EAAE,CAAC;QACjB,gBAAgB,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;IAC/C,CAAC;SAAM,CAAC;QACN,IAAI,sBAAsB,EAAE,CAAC;YAC3B,YAAY,CAAC,MAAM,CACjB,WAAW,CAAC;gBACV,IAAI,EAAE,uBAAuB,CAAW,sBAAsB,CAAC;gBAC/D,IAAI,EAAE,IAAI;gBACV,GAAG,EAAE,EAAE;gBACP,UAAU,EAAE,SAAS;aACtB,CAAC,CACH,CAAC;QACJ,CAAC;IACH,CAAC;IAED,IAAI,mBAAmB,EAAE,CAAC;QACxB,YAAY,CAAC,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE;YAC1C,mBAAmB,CAAC;gBAClB,aAAa,EAAE,KAAK;aACrB,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;IAED,OAAO,YAAY,CAAC;AACtB,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { GidsSideNavigationWebProps } from '@ganpatiinfo/gids-web-shared';
2
+ import { DomChildren } from '../../utils/domUtils.js';
3
+ import { HtmlInputAttributes } from '../GidsInput/GidsInput.js';
4
+ import { type GidsSideMenuHeaderDomProps } from '../GidsSideMenuHeader/GidsSideMenuHeader.js';
5
+ export interface GidsSideNavigationDomProps extends GidsSideNavigationWebProps<DomChildren, DomChildren, Element, HtmlInputAttributes>, Pick<GidsSideMenuHeaderDomProps, 'headerClasses' | 'wrapperClass' | 'onGidsSearchBarClear' | 'className' | 'onBlur' | 'onChange' | 'onFocus' | 'onInput'> {
6
+ extraSideNavigationClasses?: string;
7
+ }
8
+ export declare const GidsSideNavigationDom: ({ sideNavigationAppearance, headerDividedByDivider, headerClasses, extraSideNavigationClasses, customHeaderChildren, isHeaderVisible, searchVisible, children, onGidsSearchBarClear, onBlur, onChange, onFocus, onInput, ...restProps }: GidsSideNavigationDomProps) => HTMLElement;
9
+ //# sourceMappingURL=GidsSideNavigation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSideNavigation.d.ts","sourceRoot":"","sources":["../../../src/components/GidsSideNavigation/GidsSideNavigation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,0BAA0B,EAE3B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,EACL,KAAK,0BAA0B,EAEhC,MAAM,6CAA6C,CAAC;AAKrD,MAAM,WAAW,0BACf,SACE,0BAA0B,CACxB,WAAW,EACX,WAAW,EACX,OAAO,EACP,mBAAmB,CACpB,EACD,IAAI,CACF,0BAA0B,EACxB,eAAe,GACf,cAAc,GACd,sBAAsB,GACtB,WAAW,GACX,QAAQ,GACR,UAAU,GACV,SAAS,GACT,SAAS,CACZ;IACH,0BAA0B,CAAC,EAAE,MAAM,CAAC;CACrC;AAED,eAAO,MAAM,qBAAqB,GAAI,yOAenC,0BAA0B,KAAG,WA6C/B,CAAC"}
@@ -0,0 +1,36 @@
1
+ import { GidsSideNavigationWebUtils, } from '@ganpatiinfo/gids-web-shared';
2
+ import { GidsSideMenuHeaderDom, } from '../GidsSideMenuHeader/GidsSideMenuHeader.js';
3
+ import { GidsSideMenuDom } from '../GidsSideMenu/GidsSideMenu.js';
4
+ const { getGidsSideNavigationClassNames } = GidsSideNavigationWebUtils;
5
+ export const GidsSideNavigationDom = ({ sideNavigationAppearance = 'default', headerDividedByDivider = true, headerClasses, extraSideNavigationClasses, customHeaderChildren, isHeaderVisible = true, searchVisible = true, children, onGidsSearchBarClear, onBlur, onChange, onFocus, onInput, ...restProps }) => {
6
+ const sideNav = document.createElement('nav');
7
+ // FIX: Force set the physical HTML attributes so Stencil is forced to read them on boot
8
+ sideNav.setAttribute('side-navigation-appearance', sideNavigationAppearance);
9
+ sideNav.setAttribute('is-header-visible', String(isHeaderVisible));
10
+ sideNav.setAttribute('search-visible', String(searchVisible));
11
+ sideNav.setAttribute('header-divided-by-divider', String(headerDividedByDivider));
12
+ sideNav.className = getGidsSideNavigationClassNames({ sideNavigationAppearance }, extraSideNavigationClasses);
13
+ if (isHeaderVisible) {
14
+ sideNav.append(GidsSideMenuHeaderDom({
15
+ searchVisible,
16
+ headerClasses,
17
+ headerAppearance: sideNavigationAppearance,
18
+ customChildren: customHeaderChildren,
19
+ onBlur,
20
+ onChange,
21
+ onFocus,
22
+ onInput,
23
+ onGidsSearchBarClear,
24
+ headerDividedByDivider,
25
+ ...restProps,
26
+ }));
27
+ }
28
+ if (children) {
29
+ sideNav.append(GidsSideMenuDom({
30
+ children,
31
+ sideMenuAppearance: sideNavigationAppearance,
32
+ }));
33
+ }
34
+ return sideNav;
35
+ };
36
+ //# sourceMappingURL=GidsSideNavigation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsSideNavigation.js","sourceRoot":"","sources":["../../../src/components/GidsSideNavigation/GidsSideNavigation.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,0BAA0B,GAC3B,MAAM,8BAA8B,CAAC;AAGtC,OAAO,EAEL,qBAAqB,GACtB,MAAM,6CAA6C,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAElE,MAAM,EAAE,+BAA+B,EAAE,GAAG,0BAA0B,CAAC;AAwBvE,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,EACpC,wBAAwB,GAAG,SAAS,EACpC,sBAAsB,GAAG,IAAI,EAC7B,aAAa,EACb,0BAA0B,EAC1B,oBAAoB,EACpB,eAAe,GAAG,IAAI,EACtB,aAAa,GAAG,IAAI,EACpB,QAAQ,EACR,oBAAoB,EACpB,MAAM,EACN,QAAQ,EACR,OAAO,EACP,OAAO,EACP,GAAG,SAAS,EACe,EAAe,EAAE;IAC5C,MAAM,OAAO,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IAE9C,wFAAwF;IACxF,OAAO,CAAC,YAAY,CAAC,4BAA4B,EAAE,wBAAwB,CAAC,CAAC;IAC7E,OAAO,CAAC,YAAY,CAAC,mBAAmB,EAAE,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC;IACnE,OAAO,CAAC,YAAY,CAAC,gBAAgB,EAAE,MAAM,CAAC,aAAa,CAAC,CAAC,CAAC;IAC9D,OAAO,CAAC,YAAY,CAClB,2BAA2B,EAC3B,MAAM,CAAC,sBAAsB,CAAC,CAC/B,CAAC;IAEF,OAAO,CAAC,SAAS,GAAG,+BAA+B,CACjD,EAAE,wBAAwB,EAAE,EAC5B,0BAA0B,CAC3B,CAAC;IAEF,IAAI,eAAe,EAAE,CAAC;QACpB,OAAO,CAAC,MAAM,CACZ,qBAAqB,CAAC;YACpB,aAAa;YACb,aAAa;YACb,gBAAgB,EAAE,wBAAwB;YAC1C,cAAc,EAAE,oBAAoB;YACpC,MAAM;YACN,QAAQ;YACR,OAAO;YACP,OAAO;YACP,oBAAoB;YACpB,sBAAsB;YACtB,GAAG,SAAS;SACb,CAAC,CACH,CAAC;IACJ,CAAC;IAED,IAAI,QAAQ,EAAE,CAAC;QACb,OAAO,CAAC,MAAM,CACZ,eAAe,CAAC;YACd,QAAQ;YACR,kBAAkB,EAAE,wBAAwB;SAC7C,CAAC,CACH,CAAC;IACJ,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC,CAAC"}
@@ -2,7 +2,7 @@ import { type GidsTopNavigationWebProps } from '@ganpatiinfo/gids-web-shared';
2
2
  import { DomChildren, DomNodeOrString } from '../../utils/domUtils.js';
3
3
  import { GidsSearchBarDomProps } from '../GidsSearchBar/GidsSearchBar.js';
4
4
  import { GidsSegmentedControlDomProps } from '../GidsSegmentedControl/GidsSegmentedControl.js';
5
- export interface GidsTopNavigationDomProps extends GidsTopNavigationWebProps<DomChildren, DomChildren, DomChildren, DomNodeOrString, string, string, string>, Pick<GidsSearchBarDomProps, 'onBlur' | 'onChange' | 'onFocus' | 'onInput'>, Pick<GidsSegmentedControlDomProps, 'onPress'> {
5
+ export interface GidsTopNavigationDomProps extends GidsTopNavigationWebProps<DomChildren, DomChildren, DomChildren, DomNodeOrString, string, string, string, DomChildren>, Pick<GidsSearchBarDomProps, 'onBlur' | 'onChange' | 'onFocus' | 'onInput'>, Pick<GidsSegmentedControlDomProps, 'onPress'> {
6
6
  extraClasses?: string;
7
7
  }
8
8
  export declare const GidsTopNavigationDom: (props: GidsTopNavigationDomProps) => HTMLElement;
@@ -1 +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,CACP,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"}
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;AAMzD,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,WAwGF,CAAC"}