@edifice.io/react 2.2.11-develop-pedago.20250708131559 → 2.2.11-develop-enabling.20250710092201

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 (104) hide show
  1. package/dist/components/Button/Button.d.ts +1 -1
  2. package/dist/components/Dropdown/Dropdown.d.ts +4 -10
  3. package/dist/components/Dropdown/Dropdown.js +8 -24
  4. package/dist/components/Flex/Flex.d.ts +0 -1
  5. package/dist/components/Flex/Flex.js +1 -2
  6. package/dist/components/Layout/Layout.d.ts +1 -5
  7. package/dist/components/Layout/Layout.js +2 -5
  8. package/dist/components/SearchBar/SearchBar.d.ts +33 -9
  9. package/dist/components/SearchBar/SearchBar.js +30 -4
  10. package/dist/components/Tabs/components/Tabs.d.ts +3 -23
  11. package/dist/components/Tabs/components/Tabs.js +3 -8
  12. package/dist/components/Tabs/components/TabsList.d.ts +1 -15
  13. package/dist/components/Tabs/components/TabsList.js +3 -13
  14. package/dist/components/Tabs/components/TabsPanel.d.ts +1 -5
  15. package/dist/components/Tabs/components/TabsPanel.js +3 -7
  16. package/dist/hooks/useDropdown/useDropdown.d.ts +0 -2
  17. package/dist/hooks/useDropdown/useDropdown.js +0 -2
  18. package/dist/hooks/useLibraryUrl/useLibraryUrl.d.ts +1 -1
  19. package/dist/hooks/useLibraryUrl/useLibraryUrl.js +2 -2
  20. package/dist/icons-apps.js +174 -164
  21. package/dist/icons.js +90 -86
  22. package/dist/index.js +10 -12
  23. package/dist/modules/editor/components/Toolbar/TableToolbar.AddMenu.js +1 -1
  24. package/dist/modules/editor/components/Toolbar/TableToolbar.DelMenu.js +1 -1
  25. package/dist/modules/icons/components/IconLibrary.d.ts +7 -0
  26. package/dist/modules/icons/components/IconLibrary.js +12 -0
  27. package/dist/modules/icons/components/IconNotification.d.ts +7 -0
  28. package/dist/modules/icons/components/IconNotification.js +12 -0
  29. package/dist/modules/icons/components/IconStar.d.ts +7 -0
  30. package/dist/modules/icons/components/IconStar.js +13 -0
  31. package/dist/modules/icons/components/IconStarFavorite.d.ts +7 -0
  32. package/dist/modules/icons/components/IconStarFull.d.ts +7 -0
  33. package/dist/modules/icons/components/IconStarFull.js +13 -0
  34. package/dist/modules/icons/components/apps/IconAccount.js +2 -2
  35. package/dist/modules/icons/components/apps/IconActualites.js +2 -2
  36. package/dist/modules/icons/components/apps/IconAdmin.js +2 -2
  37. package/dist/modules/icons/components/apps/IconAgenda.js +3 -2
  38. package/dist/modules/icons/components/apps/IconAppointments.js +2 -2
  39. package/dist/modules/icons/components/apps/IconArchive.js +2 -2
  40. package/dist/modules/icons/components/apps/IconBlog.js +2 -2
  41. package/dist/modules/icons/components/apps/IconCahierDeTexte.js +2 -2
  42. package/dist/modules/icons/components/apps/IconCalendar.js +3 -2
  43. package/dist/modules/icons/components/apps/IconCollaborativeWall.js +2 -2
  44. package/dist/modules/icons/components/apps/IconCommunity.js +2 -2
  45. package/dist/modules/icons/components/apps/IconConversation.js +2 -2
  46. package/dist/modules/icons/components/apps/IconDirectory.js +2 -2
  47. package/dist/modules/icons/components/apps/IconEdt.d.ts +7 -0
  48. package/dist/modules/icons/components/apps/IconEdt.js +12 -0
  49. package/dist/modules/icons/components/apps/IconExercizer.js +2 -2
  50. package/dist/modules/icons/components/apps/IconForms.js +2 -6
  51. package/dist/modules/icons/components/apps/IconForum.js +2 -2
  52. package/dist/modules/icons/components/apps/IconGeogebra.d.ts +7 -0
  53. package/dist/modules/icons/components/apps/IconGeogebra.js +12 -0
  54. package/dist/modules/icons/components/apps/IconLibrary.js +2 -2
  55. package/dist/modules/icons/components/apps/IconMagneto.d.ts +7 -0
  56. package/dist/modules/icons/components/apps/IconMagneto.js +13 -0
  57. package/dist/modules/icons/components/apps/IconMediacentre.js +2 -2
  58. package/dist/modules/icons/components/apps/IconMindmap.js +2 -2
  59. package/dist/modules/icons/components/apps/IconMinetest.d.ts +7 -0
  60. package/dist/modules/icons/components/apps/IconMinetest.js +12 -0
  61. package/dist/modules/icons/components/{IconMegaphone.d.ts → apps/IconMinibadge.d.ts} +2 -2
  62. package/dist/modules/icons/components/apps/IconMinibadge.js +12 -0
  63. package/dist/modules/icons/components/apps/IconMoodle.js +2 -2
  64. package/dist/modules/icons/components/apps/IconNabook.js +2 -4
  65. package/dist/modules/icons/components/apps/IconNotebook.js +2 -2
  66. package/dist/modules/icons/components/apps/IconPad.js +2 -2
  67. package/dist/modules/icons/components/apps/IconPages.js +2 -2
  68. package/dist/modules/icons/components/apps/IconParametrage.js +2 -2
  69. package/dist/modules/icons/components/apps/IconParametrages.js +2 -2
  70. package/dist/modules/icons/components/apps/IconPoll.js +2 -2
  71. package/dist/modules/icons/components/apps/IconPresences.js +2 -6
  72. package/dist/modules/icons/components/apps/IconRack.js +2 -2
  73. package/dist/modules/icons/components/apps/IconRbs.js +2 -2
  74. package/dist/modules/icons/components/apps/IconSchoolbook.js +2 -2
  75. package/dist/modules/icons/components/apps/IconScrapbook.js +2 -2
  76. package/dist/modules/icons/components/apps/IconSettingsClass.js +2 -2
  77. package/dist/modules/icons/components/apps/IconSharebigfiles.js +2 -2
  78. package/dist/modules/icons/components/apps/IconStatistics.js +2 -2
  79. package/dist/modules/icons/components/apps/IconSupport.js +2 -2
  80. package/dist/modules/icons/components/apps/IconTimeline.js +2 -2
  81. package/dist/modules/icons/components/apps/IconTimelinegenerator.js +2 -2
  82. package/dist/modules/icons/components/apps/IconUserbook.js +2 -2
  83. package/dist/modules/icons/components/apps/IconVisioconf.js +2 -2
  84. package/dist/modules/icons/components/apps/IconWebsite.js +2 -2
  85. package/dist/modules/icons/components/apps/IconWiki.js +3 -3
  86. package/dist/modules/icons/components/apps/IconWorkspace.js +2 -2
  87. package/dist/modules/icons/components/apps/index.d.ts +5 -0
  88. package/dist/modules/icons/components/index.d.ts +4 -2
  89. package/dist/modules/modals/OnboardingModal/OnboardingModal.d.ts +6 -4
  90. package/dist/modules/modals/OnboardingModal/OnboardingModal.js +27 -13
  91. package/dist/modules/modals/OnboardingModal/index.d.ts +1 -0
  92. package/dist/modules/modals/OnboardingModal/useOnboardingModal.js +4 -4
  93. package/dist/modules/multimedia/FileCard/FileCard.d.ts +2 -13
  94. package/dist/modules/multimedia/FileCard/FileCard.js +5 -15
  95. package/dist/modules/multimedia/FileCard/FileIcon.d.ts +1 -5
  96. package/dist/modules/multimedia/FileCard/FileIcon.js +2 -2
  97. package/dist/modules/multimedia/MediaLibrary/MediaLibrary.d.ts +1 -3
  98. package/dist/modules/multimedia/MediaLibrary/MediaLibrary.js +2 -7
  99. package/dist/modules/multimedia/index.d.ts +0 -1
  100. package/dist/multimedia.js +10 -12
  101. package/package.json +6 -6
  102. package/dist/modules/icons/components/IconMegaphone.js +0 -12
  103. package/dist/modules/icons/components/IconNotes.d.ts +0 -7
  104. package/dist/modules/icons/components/IconNotes.js +0 -13
@@ -2,7 +2,7 @@ import { ReactNode } from 'react';
2
2
  import { LoadingIcon, LoadingPosition } from '../Loading';
3
3
  export type ButtonRef = HTMLButtonElement;
4
4
  export type ButtonTypes = 'button' | 'submit' | 'reset';
5
- export type ButtonColors = 'primary' | 'secondary' | 'tertiary' | 'danger';
5
+ export type ButtonColors = 'primary' | 'secondary' | 'tertiary' | 'danger' | 'black';
6
6
  export type ButtonVariants = 'filled' | 'outline' | 'ghost';
7
7
  export type ButtonSizes = 'sm' | 'md' | 'lg';
8
8
  export interface ButtonProps extends React.ComponentPropsWithRef<'button'> {
@@ -1,15 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { Placement } from '@floating-ui/react';
3
3
  import { default as DropdownCheckboxItem } from './DropdownCheckboxItem';
4
- export interface DropdownApi {
5
- visible: boolean;
6
- isFocused: string | null;
7
- menuRef: React.MutableRefObject<HTMLUListElement | null>;
8
- triggerRef: React.MutableRefObject<HTMLButtonElement | null>;
9
- setVisible: (visible: boolean) => void;
10
- openDropdown: () => void;
11
- closeDropdown: () => void;
12
- }
13
4
  export interface DropdownProps {
14
5
  /** Children Props */
15
6
  children: ReactNode | ((...props: any) => ReactNode);
@@ -77,7 +68,10 @@ export type DropdownMenuOptions = {
77
68
  */
78
69
  type: 'divider';
79
70
  };
80
- declare const Dropdown: import('react').ForwardRefExoticComponent<DropdownProps & import('react').RefAttributes<DropdownApi>> & {
71
+ declare const Dropdown: {
72
+ ({ children, block, overflow, noWrap, placement, extraTriggerKeyDownHandler, onToggle, isTriggerHovered, focusOnVisible, openOnSpace, focusOnMouseEnter, }: DropdownProps): import("react/jsx-runtime").JSX.Element;
73
+ displayName: string;
74
+ } & {
81
75
  Trigger: import('react').ForwardRefExoticComponent<Omit<import('./DropdownTrigger').DropdownTriggerProps, "ref"> & import('react').RefAttributes<HTMLButtonElement>>;
82
76
  Menu: import('react').ForwardRefExoticComponent<Omit<import('./DropdownMenu').DropdownMenuProps, "ref"> & import('react').RefAttributes<HTMLDivElement>>;
83
77
  Item: {
@@ -1,5 +1,5 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
- import { forwardRef, useImperativeHandle, useMemo, useEffect } from "react";
2
+ import { useMemo, useEffect } from "react";
3
3
  import clsx from "clsx";
4
4
  import useDropdown from "../../hooks/useDropdown/useDropdown.js";
5
5
  import DropdownCheckboxItem from "./DropdownCheckboxItem.js";
@@ -11,7 +11,7 @@ import DropdownRadioItem from "./DropdownRadioItem.js";
11
11
  import DropdownSeparator from "./DropdownSeparator.js";
12
12
  import DropdownTrigger from "./DropdownTrigger.js";
13
13
  import useClickOutside from "../../hooks/useClickOutside/useClickOutside.js";
14
- const Root = /* @__PURE__ */ forwardRef(({
14
+ const Root = ({
15
15
  children,
16
16
  block,
17
17
  overflow = !0,
@@ -23,7 +23,7 @@ const Root = /* @__PURE__ */ forwardRef(({
23
23
  focusOnVisible = !0,
24
24
  openOnSpace = !0,
25
25
  focusOnMouseEnter = !0
26
- }, refDropdown) => {
26
+ }) => {
27
27
  const {
28
28
  visible,
29
29
  isFocused,
@@ -31,22 +31,8 @@ const Root = /* @__PURE__ */ forwardRef(({
31
31
  menuProps,
32
32
  itemProps,
33
33
  itemRefs,
34
- setVisible,
35
- menuRef,
36
- triggerRef,
37
- closeDropdown,
38
- openDropdown
39
- } = useDropdown(placement, extraTriggerKeyDownHandler, isTriggerHovered, focusOnVisible, openOnSpace, focusOnMouseEnter);
40
- useImperativeHandle(refDropdown, () => ({
41
- visible,
42
- setVisible,
43
- isFocused,
44
- menuRef,
45
- triggerRef,
46
- closeDropdown,
47
- openDropdown
48
- }));
49
- const ref = useClickOutside(() => {
34
+ setVisible
35
+ } = useDropdown(placement, extraTriggerKeyDownHandler, isTriggerHovered, focusOnVisible, openOnSpace, focusOnMouseEnter), ref = useClickOutside(() => {
50
36
  setVisible(!1);
51
37
  }), value = useMemo(() => ({
52
38
  visible,
@@ -56,10 +42,8 @@ const Root = /* @__PURE__ */ forwardRef(({
56
42
  itemProps,
57
43
  itemRefs,
58
44
  block,
59
- setVisible,
60
- openDropdown,
61
- closeDropdown
62
- }), [visible, isFocused, triggerProps, menuProps, itemProps, itemRefs, block, setVisible, openDropdown, closeDropdown]), dropdown = clsx("dropdown", {
45
+ setVisible
46
+ }), [visible, isFocused, triggerProps, menuProps, itemProps, itemRefs, block, setVisible]), dropdown = clsx("dropdown", {
63
47
  "w-100": block,
64
48
  "dropdown-nowrap": noWrap,
65
49
  overflow
@@ -67,7 +51,7 @@ const Root = /* @__PURE__ */ forwardRef(({
67
51
  return useEffect(() => {
68
52
  onToggle == null || onToggle(visible);
69
53
  }, [visible]), /* @__PURE__ */ jsx(DropdownContext.Provider, { value, children: /* @__PURE__ */ jsx("div", { ref, className: dropdown, children: typeof children == "function" ? children(triggerProps, itemRefs, setVisible) : children }) });
70
- }), Dropdown = /* @__PURE__ */ Object.assign(Root, {
54
+ }, Dropdown = /* @__PURE__ */ Object.assign(Root, {
71
55
  Trigger: DropdownTrigger,
72
56
  Menu: DropdownMenu,
73
57
  Item: DropdownItem,
@@ -5,7 +5,6 @@ interface FlexProps extends React.HTMLAttributes<HTMLElement> {
5
5
  align?: 'start' | 'end' | 'center' | 'baseline' | 'stretch';
6
6
  justify?: 'start' | 'end' | 'center' | 'between' | 'around' | 'evenly';
7
7
  gap?: string;
8
- fill?: boolean;
9
8
  wrap?: 'wrap' | 'nowrap' | 'reverse';
10
9
  className?: string;
11
10
  }
@@ -6,13 +6,12 @@ const Flex = ({
6
6
  align,
7
7
  justify,
8
8
  gap,
9
- fill,
10
9
  wrap = "wrap",
11
10
  className,
12
11
  children,
13
12
  ...restProps
14
13
  }) => {
15
- const classes = clsx("d-flex", direction && `flex-${direction}`, fill && "flex-fill", align && `align-items-${align}`, justify && `justify-content-${justify}`, gap && `gap-${gap}`, wrap && `flex-${wrap}`, className);
14
+ const classes = clsx("d-flex", direction && (direction === "fill" ? "flex-fill" : `flex-${direction}`), align && `align-items-${align}`, justify && `justify-content-${justify}`, gap && `gap-${gap}`, wrap && `flex-${wrap}`, className);
16
15
  return /* @__PURE__ */ jsx(Component, { className: classes, ...restProps, children });
17
16
  };
18
17
  export {
@@ -4,13 +4,9 @@ export interface LayoutProps extends ComponentPropsWithoutRef<any> {
4
4
  children: ReactNode;
5
5
  /** Full screen mode without header component */
6
6
  headless?: boolean;
7
- /** Control white background - defaults to true */
8
- whiteBg?: boolean;
9
- /** Additional class name */
10
- className?: string;
11
7
  }
12
8
  export declare const Layout: {
13
- ({ children, headless, whiteBg, className, ...restProps }: LayoutProps): import("react/jsx-runtime").JSX.Element;
9
+ ({ children, headless, ...restProps }: LayoutProps): import("react/jsx-runtime").JSX.Element;
14
10
  displayName: string;
15
11
  };
16
12
  export default Layout;
@@ -12,8 +12,6 @@ import Button from "../Button/Button.js";
12
12
  const Layout = ({
13
13
  children,
14
14
  headless = !1,
15
- whiteBg = !0,
16
- className,
17
15
  ...restProps
18
16
  }) => {
19
17
  const {
@@ -26,12 +24,11 @@ const Layout = ({
26
24
  handleCloseCookiesConsent
27
25
  } = useCookiesConsent();
28
26
  useZendeskGuide(), useCantoo();
29
- const classes = clsx("d-flex flex-column", {
30
- "bg-white": whiteBg,
27
+ const classes = clsx("d-flex flex-column bg-white", {
31
28
  "container-fluid": !headless,
32
29
  "rounded-4 border": (theme == null ? void 0 : theme.is1d) && !headless,
33
30
  "mt-24": (theme == null ? void 0 : theme.is1d) && !headless
34
- }, className), renderHeader = headless ? null : /* @__PURE__ */ jsx(Header, { is1d: theme == null ? void 0 : theme.is1d, src: theme == null ? void 0 : theme.basePath }), renderCookies = showCookiesConsent && /* @__PURE__ */ jsx(Alert, { type: "info", className: "m-12 rgpd", isConfirm: !0, position: "bottom-right", button: /* @__PURE__ */ jsx(Button, { color: "tertiary", variant: "ghost", onClick: handleConsultCookies, children: t("rgpd.cookies.banner.button.consult") }), onClose: handleCloseCookiesConsent, children: t("rgpd.cookies.banner.text1") }), renderToaster = /* @__PURE__ */ jsx(Toaster, { containerClassName: "toaster-container", toastOptions: {
31
+ }), renderHeader = headless ? null : /* @__PURE__ */ jsx(Header, { is1d: theme == null ? void 0 : theme.is1d, src: theme == null ? void 0 : theme.basePath }), renderCookies = showCookiesConsent && /* @__PURE__ */ jsx(Alert, { type: "info", className: "m-12 rgpd", isConfirm: !0, position: "bottom-right", button: /* @__PURE__ */ jsx(Button, { color: "tertiary", variant: "ghost", onClick: handleConsultCookies, children: t("rgpd.cookies.banner.button.consult") }), onClose: handleCloseCookiesConsent, children: t("rgpd.cookies.banner.text1") }), renderToaster = /* @__PURE__ */ jsx(Toaster, { containerClassName: "toaster-container", toastOptions: {
35
32
  position: "top-right"
36
33
  } });
37
34
  return /* @__PURE__ */ jsxs(Fragment, { children: [
@@ -1,16 +1,19 @@
1
1
  import { ChangeEvent } from 'react';
2
2
  import { Size } from '../../types';
3
+ /**
4
+ * Base props shared by both SearchBar variants
5
+ */
3
6
  export interface BaseProps extends Omit<React.ComponentPropsWithoutRef<'input'>, 'size'> {
4
7
  /**
5
- * String or Template literal with React i18next namespace
8
+ * String or template literal key for i18next translation
6
9
  */
7
10
  placeholder?: string;
8
11
  /**
9
- * Control SearchBar size
12
+ * Control SearchBar size (excluding 'sm')
10
13
  */
11
14
  size?: Exclude<Size, 'sm'>;
12
15
  /**
13
- * Disabled status
16
+ * Disable the input
14
17
  */
15
18
  disabled?: boolean;
16
19
  /**
@@ -19,37 +22,58 @@ export interface BaseProps extends Omit<React.ComponentPropsWithoutRef<'input'>,
19
22
  buttonDisabled?: boolean;
20
23
  /**
21
24
  * Optional class for styling purpose
25
+ * Optional class for custom styling
22
26
  */
23
27
  className?: string;
24
28
  /**
25
- * ChangeEvent Handler
29
+ * onChange handler for input changes
26
30
  */
27
31
  onChange?: (e: ChangeEvent<HTMLInputElement>) => void;
32
+ /**
33
+ * Current value of the input
34
+ */
35
+ value?: string;
36
+ /**
37
+ * Show a clear (reset) button when value is present
38
+ */
39
+ clearable?: boolean;
28
40
  }
41
+ /**
42
+ * Default SearchBar with a submit button
43
+ */
29
44
  type DefaultSearchBar = {
30
45
  /**
31
- * Switch between button or dynamic search bar
46
+ * Use false to render the default SearchBar (with a button)
32
47
  */
33
48
  isVariant: false;
34
49
  /**
35
- * Handle Search with Default SearchBar
50
+ * Callback when clicking the search button
36
51
  */
37
52
  onClick: () => void;
38
53
  };
54
+ /**
55
+ * Dynamic SearchBar with icon and no submit button
56
+ */
39
57
  type DynamicSearchBar = {
40
58
  /**
41
- * Switch between button or dynamic search bar
59
+ * Use true to render the dynamic SearchBar (with an icon inside input)
42
60
  */
43
61
  isVariant: true;
44
62
  /**
45
- * Handle Search with Default SearchBar
63
+ * onClick must be undefined for dynamic variant
46
64
  */
47
65
  onClick?: undefined;
48
66
  };
67
+ /**
68
+ * Props for the SearchBar component
69
+ */
49
70
  export type Props = DefaultSearchBar | DynamicSearchBar;
50
71
  export type SearchBarProps = BaseProps & Props;
72
+ /**
73
+ * SearchBar component to handle dynamic or static search input
74
+ */
51
75
  declare const SearchBar: {
52
- ({ isVariant, size, placeholder, className, disabled, buttonDisabled, onChange, onClick, ...restProps }: SearchBarProps): import("react/jsx-runtime").JSX.Element;
76
+ ({ isVariant, size, placeholder, className, disabled, buttonDisabled, onChange, onClick, value, clearable, ...restProps }: SearchBarProps): import("react/jsx-runtime").JSX.Element;
53
77
  displayName: string;
54
78
  };
55
79
  export default SearchBar;
@@ -1,6 +1,7 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import clsx from "clsx";
3
3
  import { useTranslation } from "react-i18next";
4
+ import SvgIconClose from "../../modules/icons/components/IconClose.js";
4
5
  import SvgIconSearch from "../../modules/icons/components/IconSearch.js";
5
6
  import FormControl from "../Form/FormControl.js";
6
7
  import SearchButton from "../Button/SearchButton.js";
@@ -13,6 +14,8 @@ const SearchBar = ({
13
14
  buttonDisabled,
14
15
  onChange,
15
16
  onClick,
17
+ value,
18
+ clearable = !1,
16
19
  ...restProps
17
20
  }) => {
18
21
  const {
@@ -22,15 +25,38 @@ const SearchBar = ({
22
25
  "position-relative": isVariant
23
26
  }), input = clsx({
24
27
  "border-end-0": !isVariant,
25
- "ps-48": isVariant
28
+ "ps-48": isVariant,
29
+ "searchbar-hide-native-clear": isVariant && clearable
26
30
  }), handleClick = () => {
27
31
  onClick == null || onClick();
28
- }, handleKeyDown = (e) => {
29
- e.key === "Enter" && (e.preventDefault(), handleClick());
32
+ }, handleClear = () => {
33
+ const event = {
34
+ target: {
35
+ value: ""
36
+ }
37
+ };
38
+ onChange == null || onChange(event);
30
39
  };
31
40
  return /* @__PURE__ */ jsxs(FormControl, { id: "search-bar", className: searchbar, children: [
32
41
  isVariant && /* @__PURE__ */ jsx("div", { className: "position-absolute z-1 top-50 start-0 translate-middle-y border-0 ps-12 bg-transparent", children: /* @__PURE__ */ jsx(SvgIconSearch, {}) }),
33
- /* @__PURE__ */ jsx(FormControl.Input, { type: "search", placeholder: t(placeholder), size, noValidationIcon: !0, className: input, onChange, disabled, onKeyDown: handleKeyDown, ...restProps }),
42
+ /* @__PURE__ */ jsx(
43
+ FormControl.Input,
44
+ {
45
+ type: "search",
46
+ placeholder: t(placeholder),
47
+ size,
48
+ noValidationIcon: !0,
49
+ className: input,
50
+ onChange,
51
+ value,
52
+ disabled,
53
+ ...restProps
54
+ }
55
+ ),
56
+ isVariant && clearable && value && onChange && /* @__PURE__ */ jsx("button", { type: "button", onClick: handleClear, className: "position-absolute end-0 top-50 translate-middle-y pe-12 bg-transparent border-0", "aria-label": t("clear"), children: /* @__PURE__ */ jsx(SvgIconClose, { className: "color-gray", style: {
57
+ width: 12,
58
+ height: 12
59
+ } }) }),
34
60
  !isVariant && /* @__PURE__ */ jsx(SearchButton, { type: "submit", "aria-label": t("search"), icon: /* @__PURE__ */ jsx(SvgIconSearch, {}), className: "border-start-0", onClick: handleClick, disabled: buttonDisabled })
35
61
  ] });
36
62
  };
@@ -17,32 +17,12 @@ export interface TabsProps {
17
17
  * Children Props
18
18
  */
19
19
  children?: (...props: any) => ReactNode;
20
- /**
21
- * Whether tabs should take full available width
22
- */
23
- fullWidth?: boolean;
24
- /**
25
- * Whether tabs should take full available height
26
- */
27
- fullHeight?: boolean;
28
- /**
29
- * Whether the tab list should be sticky
30
- */
31
- isSticky?: boolean;
32
- /**
33
- * The top offset for the sticky tab list
34
- */
35
- stickyTop?: number;
36
- /**
37
- * Additional class names for the Tabs component
38
- */
39
- className?: string;
40
20
  }
41
21
  /**
42
22
  * Tab Content displayed one at a time when a Tab Item is selected
43
23
  */
44
24
  export declare const Tabs: {
45
- ({ defaultId, items, fullWidth, fullHeight, onChange, children, isSticky, stickyTop, className, }: TabsProps): import("react/jsx-runtime").JSX.Element;
25
+ ({ defaultId, items, onChange, children }: TabsProps): import("react/jsx-runtime").JSX.Element;
46
26
  Item: {
47
27
  ({ icon, badge, label, id, order, }: TabsItemProps & {
48
28
  order: number;
@@ -50,11 +30,11 @@ export declare const Tabs: {
50
30
  displayName: string;
51
31
  };
52
32
  Panel: {
53
- ({ children, currentItem, fullHeight }: import('./TabsPanel').TabsPanelProps): import("react/jsx-runtime").JSX.Element;
33
+ ({ children, currentItem }: import('./TabsPanel').TabsPanelProps): import("react/jsx-runtime").JSX.Element;
54
34
  displayName: string;
55
35
  };
56
36
  List: {
57
- (props: import('./TabsList').TabsListProps): import("react/jsx-runtime").JSX.Element;
37
+ (props: import('react').ComponentPropsWithoutRef<"div">): import("react/jsx-runtime").JSX.Element;
58
38
  displayName: string;
59
39
  };
60
40
  displayName: string;
@@ -8,13 +8,8 @@ import TabsPanel from "./TabsPanel.js";
8
8
  const Tabs = ({
9
9
  defaultId,
10
10
  items,
11
- fullWidth = !1,
12
- fullHeight = !1,
13
11
  onChange,
14
- children,
15
- isSticky = !1,
16
- stickyTop = 0,
17
- className
12
+ children
18
13
  }) => {
19
14
  const {
20
15
  activeTab,
@@ -37,8 +32,8 @@ const Tabs = ({
37
32
  onKeyDown
38
33
  }), [activeTab, items, onKeyDown, setSelectedTab, tabUnderlineLeft, tabUnderlineWidth, tabsRef]), currentItem = items.find((item) => item.id === activeTab);
39
34
  return /* @__PURE__ */ jsx(TabsContext.Provider, { value, children: typeof children == "function" ? children(currentItem) : /* @__PURE__ */ jsxs(Fragment, { children: [
40
- /* @__PURE__ */ jsx(Tabs.List, { fullWidth, isSticky, stickyTop, className }),
41
- /* @__PURE__ */ jsx(Tabs.Panel, { currentItem, fullHeight, children: currentItem == null ? void 0 : currentItem.content })
35
+ /* @__PURE__ */ jsx(Tabs.List, {}),
36
+ /* @__PURE__ */ jsx(Tabs.Panel, { currentItem, children: currentItem == null ? void 0 : currentItem.content })
42
37
  ] }) });
43
38
  };
44
39
  Tabs.Item = TabsItem;
@@ -1,20 +1,6 @@
1
1
  import { ComponentPropsWithoutRef } from 'react';
2
- export interface TabsListProps extends ComponentPropsWithoutRef<'div'> {
3
- /**
4
- * Whether tabs should take full available width
5
- */
6
- fullWidth?: boolean;
7
- /**
8
- * Whether the tab list should be sticky
9
- */
10
- isSticky?: boolean;
11
- /**
12
- * The top offset for the sticky tab list
13
- */
14
- stickyTop?: number;
15
- }
16
2
  declare const TabsList: {
17
- (props: TabsListProps): import("react/jsx-runtime").JSX.Element;
3
+ (props: ComponentPropsWithoutRef<"div">): import("react/jsx-runtime").JSX.Element;
18
4
  displayName: string;
19
5
  };
20
6
  export default TabsList;
@@ -9,20 +9,10 @@ const TabsList = (props) => {
9
9
  tabUnderlineWidth
10
10
  } = useTabsContext(), {
11
11
  className,
12
- fullWidth,
13
- isSticky,
14
- stickyTop,
15
12
  ...restProps
16
- } = props, ulClasses = clsx("nav nav-tabs flex-nowrap", {
17
- "w-100": fullWidth
18
- }), tabslist = clsx(" flex-shrink-0 overflow-x-auto", {
19
- "position-sticky z-1": isSticky,
20
- "position-relative": !isSticky
21
- }, className);
22
- return /* @__PURE__ */ jsxs("div", { className: tabslist, ...restProps, style: isSticky ? {
23
- top: stickyTop
24
- } : void 0, children: [
25
- /* @__PURE__ */ jsx("ul", { className: ulClasses, role: "tablist", children: items.map((item, order) => /* @__PURE__ */ jsx(Tabs.Item, { order, ...item }, item.id)) }),
13
+ } = props, tabslist = clsx("position-relative flex-shrink-0 overflow-x-auto", className);
14
+ return /* @__PURE__ */ jsxs("div", { className: tabslist, ...restProps, children: [
15
+ /* @__PURE__ */ jsx("ul", { className: "nav nav-tabs flex-nowrap", role: "tablist", children: items.map((item, order) => /* @__PURE__ */ jsx(Tabs.Item, { order, ...item }, item.id)) }),
26
16
  /* @__PURE__ */ jsx("span", { className: "nav-slide", style: {
27
17
  left: tabUnderlineLeft,
28
18
  width: tabUnderlineWidth
@@ -9,13 +9,9 @@ export interface TabsPanelProps {
9
9
  * Current Item
10
10
  */
11
11
  currentItem: TabsItemProps | undefined;
12
- /**
13
- * Whether tabs should take full available height
14
- */
15
- fullHeight?: boolean;
16
12
  }
17
13
  declare const TabsPanel: {
18
- ({ children, currentItem, fullHeight }: TabsPanelProps): import("react/jsx-runtime").JSX.Element;
14
+ ({ children, currentItem }: TabsPanelProps): import("react/jsx-runtime").JSX.Element;
19
15
  displayName: string;
20
16
  };
21
17
  export default TabsPanel;
@@ -1,17 +1,13 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { useTabsContext } from "../context/TabsContext.js";
3
- import clsx from "clsx";
4
3
  const TabsPanel = ({
5
4
  children,
6
- currentItem,
7
- fullHeight
5
+ currentItem
8
6
  }) => {
9
7
  const {
10
8
  activeTab
11
- } = useTabsContext(), contentClasses = clsx("tab-content d-flex flex-fill w-100", {
12
- "position-relative h-100": fullHeight
13
- });
14
- return /* @__PURE__ */ jsx("div", { className: contentClasses, children: /* @__PURE__ */ jsx("div", { className: `tab-pane flex-fill w-100 fade ${activeTab === (currentItem == null ? void 0 : currentItem.id) ? "show active" : ""}`, id: `tabpanel-${currentItem == null ? void 0 : currentItem.id}`, role: "tabpanel", "aria-labelledby": `tab-${currentItem == null ? void 0 : currentItem.id}`, tabIndex: 0, children }) });
9
+ } = useTabsContext();
10
+ return /* @__PURE__ */ jsx("div", { className: "tab-content d-flex flex-fill w-100", children: /* @__PURE__ */ jsx("div", { className: `tab-pane flex-fill w-100 fade ${activeTab === (currentItem == null ? void 0 : currentItem.id) ? "show active" : ""}`, id: `tabpanel-${currentItem == null ? void 0 : currentItem.id}`, role: "tabpanel", "aria-labelledby": `tab-${currentItem == null ? void 0 : currentItem.id}`, tabIndex: 0, children }) });
15
11
  };
16
12
  export {
17
13
  TabsPanel as default
@@ -28,8 +28,6 @@ export interface UseDropdownProps {
28
28
  itemProps: Record<string, any>;
29
29
  setVisible: Dispatch<SetStateAction<boolean>>;
30
30
  openOnSpace?: boolean;
31
- openDropdown: () => void;
32
- closeDropdown: () => void;
33
31
  }
34
32
  declare const useDropdown: (placement: Placement | undefined, extraTriggerKeyDownHandler?: (event: React.KeyboardEvent<HTMLButtonElement>) => void, isTriggerHovered?: boolean, focusOnVisible?: boolean, openOnSpace?: boolean, focusOnMouseEnter?: boolean) => UseDropdownProps;
35
33
  export default useDropdown;
@@ -159,8 +159,6 @@ const useDropdown = (placement, extraTriggerKeyDownHandler, isTriggerHovered = !
159
159
  onMenuItemClick: closeDropdown,
160
160
  onMenuItemKeyDown
161
161
  },
162
- openDropdown,
163
- closeDropdown,
164
162
  setVisible
165
163
  };
166
164
  };
@@ -3,5 +3,5 @@
3
3
  *
4
4
  * @returns the Library URL as a string. Returns null if no library was found in user apps.
5
5
  */
6
- declare const useLibraryUrl: () => string | null;
6
+ declare const useLibraryUrl: (appCodeName?: string) => string | null;
7
7
  export default useLibraryUrl;
@@ -1,11 +1,11 @@
1
1
  import { libraryMaps } from "@edifice.io/utilities";
2
2
  import { useEdificeClient } from "../../providers/EdificeClientProvider/EdificeClientProvider.hook.js";
3
- const useLibraryUrl = () => {
3
+ const useLibraryUrl = (appCodeName) => {
4
4
  var _a;
5
5
  const {
6
6
  user,
7
7
  appCode
8
- } = useEdificeClient(), appName = libraryMaps[appCode], libraryApp = user == null ? void 0 : user.apps.find((app) => app.isExternal && app.address.includes("library"));
8
+ } = useEdificeClient(), appName = libraryMaps[appCodeName ?? appCode], libraryApp = user == null ? void 0 : user.apps.find((app) => app.isExternal && app.address.includes("library"));
9
9
  if (!libraryApp)
10
10
  return null;
11
11
  const libraryUrlSplit = (_a = libraryApp.address) == null ? void 0 : _a.split("?");