@fibery/ui-kit 9.0.2 → 9.1.1

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 (189) hide show
  1. package/lib/a11y-color.js +12 -10
  2. package/lib/actions-menu/actions-menu-props.d.ts +2 -0
  3. package/lib/actions-menu/actions-menu-sub-command-menu.js +5 -4
  4. package/lib/actions-menu/actions-menu.d.ts +1 -1
  5. package/lib/actions-menu/actions-menu.js +2 -1
  6. package/lib/actions-menu/contexts/actions-menu-context.js +12 -11
  7. package/lib/ai/max-tokens.js +6 -5
  8. package/lib/antd/ant-modal.d.ts +1 -1
  9. package/lib/antd/ant-modal.js +28 -1
  10. package/lib/antd/ant-upload.d.ts +1 -1
  11. package/lib/antd/ant-upload.js +23 -18
  12. package/lib/antd/input.js +5 -4
  13. package/lib/antd/utils.js +2 -1
  14. package/lib/avatar-colors.js +1 -1
  15. package/lib/avatar.d.ts +1 -10
  16. package/lib/avatar.js +48 -38
  17. package/lib/avatar.wyw-in-js.css +1 -1
  18. package/lib/banner/banner-action.js +2 -1
  19. package/lib/button/button.js +1 -1
  20. package/lib/button/icon-button.js +1 -1
  21. package/lib/canvas-colors.js +2 -2
  22. package/lib/card-container.d.ts +2 -6
  23. package/lib/card-container.js +4 -4
  24. package/lib/color-filter.js +2 -2
  25. package/lib/color-inspect.js +1 -1
  26. package/lib/color-picker/color-picker-or-loader.d.ts +2 -2
  27. package/lib/color-utils.js +1 -1
  28. package/lib/comment.d.ts +2 -1
  29. package/lib/comment.js +44 -27
  30. package/lib/comment.wyw-in-js.css +11 -8
  31. package/lib/context-menu/index.js +1 -0
  32. package/lib/context-menu/index.wyw-in-js.css +1 -1
  33. package/lib/date-picker/autocomplete.js +12 -10
  34. package/lib/date-picker/date-range-input.js +8 -6
  35. package/lib/date-picker/day-with-start-end-buttons.js +0 -2
  36. package/lib/date-picker/get-weekends-for-month.js +4 -2
  37. package/lib/date-picker/single-date-input.js +8 -6
  38. package/lib/day-select/day-select.js +2 -1
  39. package/lib/day-select/week-day-select.d.ts +2 -2
  40. package/lib/day-select/week-day-select.js +4 -3
  41. package/lib/design-system/alpha.js +5 -7
  42. package/lib/design-system/colors-charts.d.ts +4 -0
  43. package/lib/design-system/colors-charts.js +14 -0
  44. package/lib/design-system/colors-js.d.ts +2 -4
  45. package/lib/design-system/colors-js.js +8 -10
  46. package/lib/design-system/fns.enum.js +7 -4
  47. package/lib/design-system/fns.icon.js +1 -1
  48. package/lib/design-system/fns.js +7 -4
  49. package/lib/design-system/theme.d.ts +7 -7
  50. package/lib/design-system/theme.js +7 -12
  51. package/lib/design-system/vars.js +1 -2
  52. package/lib/design-system.d.ts +3 -2
  53. package/lib/design-system.js +3 -2
  54. package/lib/emoji-picker/primitives/content.js +10 -9
  55. package/lib/emoji-picker/primitives/emoji.js +22 -14
  56. package/lib/emoji-picker/primitives/emoji.wyw-in-js.css +4 -3
  57. package/lib/emoji-picker/primitives/grid.js +0 -1
  58. package/lib/emoji-picker/primitives/preview-provider.js +4 -3
  59. package/lib/emoji-picker/primitives/root.js +10 -9
  60. package/lib/emoji-picker/primitives/skin-provider.js +5 -4
  61. package/lib/emoji-picker/stores/emoji-data-store.d.ts +2 -2
  62. package/lib/emoji-picker/stores/emoji-data-store.js +8 -8
  63. package/lib/emoji-picker/stores/static-emoji-data-store.js +2 -1
  64. package/lib/emoji.js +5 -2
  65. package/lib/fibermoji-placeholder.js +5 -7
  66. package/lib/field-type-icon.js +2 -1
  67. package/lib/file-item/file-icon.js +2 -1
  68. package/lib/file-item.js +3 -10
  69. package/lib/highlight-colors.js +2 -1
  70. package/lib/hotkey-scope.js +2 -1
  71. package/lib/icons/ast/index.d.ts +1 -4
  72. package/lib/icons/ast/index.js +2 -5
  73. package/lib/icons/ast/spinner.js +1 -14
  74. package/lib/icons/icon.js +4 -3
  75. package/lib/icons/react/index.d.ts +1 -4
  76. package/lib/icons/react/index.js +2 -5
  77. package/lib/images-gallery/get-gallery-src.js +1 -1
  78. package/lib/images-gallery/slide-buttons.js +8 -4
  79. package/lib/images-gallery/thumbnails-mime-types-white-list.js +1 -1
  80. package/lib/integration-compact-info-button.js +1 -1
  81. package/lib/loading-sausage.js +7 -6
  82. package/lib/mobile-drawer.d.ts +2 -1
  83. package/lib/mobile-drawer.js +24 -12
  84. package/lib/mobile-drawer.wyw-in-js.css +3 -2
  85. package/lib/mobile-keyboard-aware-popup.js +6 -5
  86. package/lib/modal-menu/contexts/modal-menu-context.d.ts +1 -0
  87. package/lib/modal-menu/modal-menu-content.d.ts +1 -1
  88. package/lib/modal-menu/modal-menu-content.js +16 -6
  89. package/lib/modal-menu/modal-menu-drawer-content.d.ts +7 -0
  90. package/lib/modal-menu/modal-menu-drawer-content.js +13 -0
  91. package/lib/modal-menu/modal-menu-root.d.ts +2 -1
  92. package/lib/modal-menu/modal-menu-root.js +24 -21
  93. package/lib/modal-menu/modal-submenu.js +10 -9
  94. package/lib/nested-menu-item.d.ts +1 -1
  95. package/lib/number-input/number-input-inline-with-autosize.d.ts +1 -2
  96. package/lib/number-input/number-input-inline-with-autosize.js +9 -6
  97. package/lib/number-input/number-input-inline-with-autosize.wyw-in-js.css +0 -1
  98. package/lib/number-input/number-input.js +13 -11
  99. package/lib/number-input/styles.d.ts +1 -9
  100. package/lib/number-input/styles.js +3 -9
  101. package/lib/number-input/styles.wyw-in-js.css +2 -3
  102. package/lib/number-input/text-area-auto-sized.d.ts +1 -2
  103. package/lib/number-input/text-area-auto-sized.js +2 -2
  104. package/lib/number-input/text-input-auto-sized.d.ts +1 -2
  105. package/lib/number-input/text-input-auto-sized.js +2 -2
  106. package/lib/online-users.js +2 -2
  107. package/lib/open-popover-tracker.js +7 -6
  108. package/lib/palettes/neutral.js +1 -1
  109. package/lib/palettes/warm.js +1 -1
  110. package/lib/phone.js +1 -1
  111. package/lib/popover/index.d.ts +4 -2
  112. package/lib/popover/index.js +61 -59
  113. package/lib/popover/mobile-popover-context.js +12 -11
  114. package/lib/popover/mobile-popover.js +16 -15
  115. package/lib/popover/modifiers.js +4 -4
  116. package/lib/preference-setting.js +6 -8
  117. package/lib/reactions/reaction-button.js +36 -25
  118. package/lib/reactions/reaction-button.wyw-in-js.css +16 -16
  119. package/lib/reactions/reaction-picker.js +22 -10
  120. package/lib/reactions/reaction-picker.wyw-in-js.css +1 -0
  121. package/lib/reactions/tootltip.js +2 -1
  122. package/lib/select/components/option.js +2 -1
  123. package/lib/select/index.d.ts +2 -1
  124. package/lib/select/select-trigger.d.ts +4 -0
  125. package/lib/select/select-trigger.js +25 -0
  126. package/lib/select/select-trigger.wyw-in-js.css +1 -0
  127. package/lib/select/select.d.ts +6 -2
  128. package/lib/select/select.js +10 -5
  129. package/lib/spinner.d.ts +2 -6
  130. package/lib/spinner.js +11 -7
  131. package/lib/spinner.wyw-in-js.css +1 -0
  132. package/lib/tab-nav/tab-nav.d.ts +4 -2
  133. package/lib/tab-nav/tab-nav.js +2 -2
  134. package/lib/thematic.js +322 -321
  135. package/lib/theme-provider.d.ts +1 -3
  136. package/lib/toast/toast-action.js +2 -1
  137. package/lib/toast/toast-provider.d.ts +1 -2
  138. package/lib/toast/toast-queue.d.ts +1 -2
  139. package/lib/toast/toast-queue.js +7 -8
  140. package/lib/toast/toast.js +7 -6
  141. package/lib/toggle.js +3 -3
  142. package/lib/tooltip-if-overflown.js +2 -1
  143. package/lib/tooltip.js +1 -1
  144. package/lib/type-badge.d.ts +8 -28
  145. package/lib/type-badge.js +39 -50
  146. package/lib/type-badge.wyw-in-js.css +11 -10
  147. package/lib/unit/container.d.ts +12 -0
  148. package/lib/unit/container.js +50 -0
  149. package/lib/unit/context.d.ts +29 -0
  150. package/lib/unit/context.js +9 -0
  151. package/lib/unit/index.d.ts +4 -2
  152. package/lib/unit/index.js +2 -1
  153. package/lib/unit/nav-button.d.ts +12 -0
  154. package/lib/unit/nav-button.js +18 -0
  155. package/lib/unit/styles.d.ts +6 -9
  156. package/lib/unit/styles.js +13 -16
  157. package/lib/unit/styles.wyw-in-js.css +10 -16
  158. package/lib/unit/unit-content-layout.d.ts +4 -3
  159. package/lib/unit/unit-content-layout.js +9 -9
  160. package/lib/unit/unit-content.d.ts +6 -5
  161. package/lib/unit/unit-content.js +83 -18
  162. package/lib/unit/unit-content.wyw-in-js.css +6 -2
  163. package/lib/unit/unit.d.ts +38 -5
  164. package/lib/unit/unit.js +43 -12
  165. package/lib/workflow-progress-icon.js +2 -2
  166. package/package.json +6 -6
  167. package/lib/features.d.ts +0 -8
  168. package/lib/features.js +0 -15
  169. package/lib/flags.d.ts +0 -4
  170. package/lib/flags.js +0 -7
  171. package/lib/icons/ast/alert-triangle.d.ts +0 -5
  172. package/lib/icons/ast/alert-triangle.js +0 -25
  173. package/lib/icons/ast/field-units-large.d.ts +0 -5
  174. package/lib/icons/ast/field-units-large.js +0 -25
  175. package/lib/icons/ast/plus.d.ts +0 -5
  176. package/lib/icons/ast/plus.js +0 -25
  177. package/lib/icons/react/alert-triangle.d.ts +0 -15
  178. package/lib/icons/react/alert-triangle.js +0 -21
  179. package/lib/icons/react/field-units-large.d.ts +0 -15
  180. package/lib/icons/react/field-units-large.js +0 -21
  181. package/lib/icons/react/plus.d.ts +0 -15
  182. package/lib/icons/react/plus.js +0 -21
  183. package/lib/unit/primitive.d.ts +0 -5
  184. package/lib/unit/primitive.js +0 -108
  185. package/lib/unit/primitive.wyw-in-js.css +0 -3
  186. package/lib/unit/types.d.ts +0 -34
  187. package/lib/unit/types.js +0 -0
  188. package/lib/unit/unit-button-group.d.ts +0 -13
  189. package/lib/unit/unit-button-group.js +0 -23
@@ -1,21 +0,0 @@
1
- import { Icon } from "../icon.js";
2
- import FieldUnitsLarge$1 from "../ast/field-units-large.js";
3
- import { jsx } from "react/jsx-runtime";
4
- import { forwardRef } from "react";
5
- //#region src/icons/react/field-units-large.tsx
6
- /**
7
- * This file was automatically generated. Do not edit manually.
8
- *
9
- * @see import("../svg/field-units-large.svg")
10
- * @see import("../../scripts/generate-icons.ts")
11
- */
12
- var FieldUnitsLarge = forwardRef(function FieldUnitsLarge(props, ref) {
13
- return /* @__PURE__ */ jsx(Icon, {
14
- ...props,
15
- className: props.className,
16
- ref,
17
- icon: FieldUnitsLarge$1
18
- });
19
- });
20
- //#endregion
21
- export { FieldUnitsLarge as default };
@@ -1,15 +0,0 @@
1
- //#region src/icons/react/plus.d.ts
2
- /**
3
- * This file was automatically generated. Do not edit manually.
4
- *
5
- * @see import("../svg/plus.svg")
6
- * @see import("../../scripts/generate-icons.ts")
7
- */
8
- declare const Plus: import("react").ForwardRefExoticComponent<Omit<import("react").SVGProps<SVGSVGElement>, "color" | "ref"> & {
9
- containerSize?: number;
10
- iconSize?: number;
11
- color?: string | null | undefined;
12
- colorProcessed?: boolean;
13
- } & import("react").RefAttributes<SVGSVGElement>>;
14
- //#endregion
15
- export { Plus as default };
@@ -1,21 +0,0 @@
1
- import { Icon } from "../icon.js";
2
- import Plus$1 from "../ast/plus.js";
3
- import { jsx } from "react/jsx-runtime";
4
- import { forwardRef } from "react";
5
- //#region src/icons/react/plus.tsx
6
- /**
7
- * This file was automatically generated. Do not edit manually.
8
- *
9
- * @see import("../svg/plus.svg")
10
- * @see import("../../scripts/generate-icons.ts")
11
- */
12
- var Plus = forwardRef(function Plus(props, ref) {
13
- return /* @__PURE__ */ jsx(Icon, {
14
- ...props,
15
- className: props.className,
16
- ref,
17
- icon: Plus$1
18
- });
19
- });
20
- //#endregion
21
- export { Plus as default };
@@ -1,5 +0,0 @@
1
- import { UnitPrimitiveProps } from "./types.js";
2
- //#region src/unit/primitive.d.ts
3
- declare const UnitPrimitive: ({ overflow, inline, button, multiline, children, title, fieldIcon, description, hint, icons, navButton, big, pill, tooltip, withLabel, border, color, bgColor, fontWeight, shrinkable, clickable, setMinWidth, setMinHeight, onClick, onKeyDown, invalid }: UnitPrimitiveProps) => import("react/jsx-runtime").JSX.Element;
4
- //#endregion
5
- export { UnitPrimitive };
@@ -1,108 +0,0 @@
1
- import "./primitive.wyw-in-js.css";
2
- import { themeVars } from "../theming.generated.js";
3
- import { Tooltip } from "../tooltip.js";
4
- import { useTruncated } from "../tooltip-if-overflown.js";
5
- import { FieldIcon } from "../field-icon.js";
6
- import { LabeledUnit } from "./labeled-unit.js";
7
- import { basicUnitClassName, bigSizeUnitClassName, positionUnitClass, regularSizeUnitClassName } from "./styles.js";
8
- import { UnitButtonGroup } from "./unit-button-group.js";
9
- import { UnitContent } from "./unit-content.js";
10
- /* empty css */
11
- import { jsx, jsxs } from "react/jsx-runtime";
12
- import { forwardRef } from "react";
13
- import cx from "classnames";
14
- //#region src/unit/primitive.tsx
15
- var unitDescriptionClassName = "uha1rmp-unitDescription";
16
- var tooltipTitleClassName = "tlbybtz-tooltipTitle";
17
- var resetButtonStylesClassName = "r1lb5dtf-resetButtonStyles";
18
- var ButtonComponent = forwardRef((props, ref) => {
19
- return /* @__PURE__ */ jsx("button", {
20
- ref,
21
- type: "button",
22
- ...props,
23
- className: cx(props.className, resetButtonStylesClassName)
24
- });
25
- });
26
- var DivComponent = forwardRef((props, ref) => /* @__PURE__ */ jsx("div", {
27
- ref,
28
- ...props
29
- }));
30
- var UnitPrimitive = ({ overflow = true, inline = true, button = false, multiline = false, children, title, fieldIcon, description = null, hint = null, icons, navButton, big = false, pill = false, tooltip = true, withLabel = false, border = true, color = themeVars.textColor, bgColor = themeVars.transparent, fontWeight, shrinkable = true, clickable = false, setMinWidth = true, setMinHeight = true, onClick, onKeyDown, invalid }) => {
31
- const { truncated, setNode } = useTruncated();
32
- const truncate = !multiline && overflow;
33
- const unitWrapperStyle = {
34
- color,
35
- backgroundColor: bgColor || themeVars.inputDisabledBgColor,
36
- fontWeight
37
- };
38
- const unitWrapperClassName = cx(basicUnitClassName, big ? bigSizeUnitClassName : regularSizeUnitClassName, setMinWidth && (big ? "b1v5rpy3-bigSizeUnitMinWidth" : "rpdarf0-regularSizeUnitMinWidth"), setMinHeight && "ubaz4qk-unitMinHeight", border && "b4mqgwc-border", pill && "p1ebg4ic-pillRadius", invalid && "i14l2yxo-invalidUnit", clickable && "c18mqj2f-clickable");
39
- const unitBody = /* @__PURE__ */ jsx(button ? ButtonComponent : DivComponent, {
40
- onKeyDown,
41
- onClick,
42
- children: jsx(UnitContent, {
43
- big,
44
- icons,
45
- shrinkable,
46
- truncate,
47
- setNode: tooltip ? setNode : void 0,
48
- children
49
- })
50
- });
51
- const renderUnit = (unit) => {
52
- const content = /* @__PURE__ */ jsx(UnitButtonGroup, {
53
- big,
54
- inline,
55
- style: unitWrapperStyle,
56
- className: unitWrapperClassName,
57
- unit,
58
- navButton
59
- });
60
- return /* @__PURE__ */ jsx("div", {
61
- className: positionUnitClass,
62
- children: withLabel ? /* @__PURE__ */ jsx(LabeledUnit, {
63
- label: title,
64
- children: content
65
- }) : content
66
- });
67
- };
68
- if (!tooltip) return renderUnit(unitBody);
69
- const tooltipTitle = /* @__PURE__ */ jsxs("div", {
70
- className: tooltipTitleClassName,
71
- children: [fieldIcon && /* @__PURE__ */ jsx(FieldIcon, {
72
- iconName: fieldIcon,
73
- iconSize: 14,
74
- color: themeVars.whiteColor
75
- }), title]
76
- });
77
- const tooltipContent = truncated && /* @__PURE__ */ jsx("div", {
78
- className: "f1kzkp39-fullUnitWrapper",
79
- children: jsx(UnitButtonGroup, {
80
- big,
81
- inline,
82
- style: unitWrapperStyle,
83
- className: unitWrapperClassName,
84
- unit: /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(UnitContent, {
85
- big,
86
- icons,
87
- children
88
- }) })
89
- })
90
- });
91
- return renderUnit(/* @__PURE__ */ jsx(Tooltip, {
92
- side: "bottom",
93
- align: "start",
94
- openOnFocus: false,
95
- title: tooltipTitle,
96
- description: (description || tooltipContent || hint) && /* @__PURE__ */ jsxs("div", { children: [
97
- description && /* @__PURE__ */ jsx("div", {
98
- className: unitDescriptionClassName,
99
- children: description
100
- }),
101
- tooltipContent,
102
- hint
103
- ] }),
104
- children: unitBody
105
- }));
106
- };
107
- //#endregion
108
- export { UnitPrimitive };
@@ -1,3 +0,0 @@
1
- .uha1rmp-unitDescription{margin-bottom:1px;}
2
- .tlbybtz-tooltipTitle{display:flex;align-items:center;gap:4px;}
3
- .r1lb5dtf-resetButtonStyles{all:unset;background-color:var(--transparent);--input-focus-border:0 0 0 1px var(--colorAccentStrokeFocus) inset;--input-focus-shadow:0 0 0 2px var(--colorAccentStroke);border-radius:6px;}.r1lb5dtf-resetButtonStyles:focus{outline:none;box-shadow:var(--input-focus-border, 0 0 0 1px var(--colorAccentStroke)),var(--input-focus-shadow)!important;transition:box-shadow 120ms ease-in-out;}.r1lb5dtf-resetButtonStyles:focus:not(:focus-visible){outline:none;box-shadow:none!important;}.r1lb5dtf-resetButtonStyles:focus-visible{outline:none;box-shadow:var(--input-focus-border, 0 0 0 1px var(--colorAccentStroke)),var(--input-focus-shadow)!important;transition:box-shadow 120ms ease-in-out;}
@@ -1,34 +0,0 @@
1
- import { KeyboardEvent, ReactNode } from "react";
2
- //#region src/unit/types.d.ts
3
- type UnitPrimitiveProps = {
4
- overflow?: boolean;
5
- inline?: boolean;
6
- button?: boolean;
7
- multiline?: boolean;
8
- children?: ReactNode;
9
- title?: ReactNode;
10
- fieldIcon?: string;
11
- description?: ReactNode;
12
- icons?: React.ReactNode[];
13
- hint?: ReactNode;
14
- navButton?: ReactNode;
15
- big?: boolean;
16
- /** Round corners to half the height (pill/stadium shape). */
17
- pill?: boolean;
18
- tooltip?: boolean;
19
- /** Render the field label above the value (full-size presentation). */
20
- withLabel?: boolean;
21
- border?: boolean;
22
- color?: string;
23
- bgColor?: string | null;
24
- fontWeight?: number;
25
- shrinkable?: boolean;
26
- clickable?: boolean;
27
- setMinWidth?: boolean;
28
- setMinHeight?: boolean;
29
- onKeyDown?: (e: KeyboardEvent<HTMLButtonElement | HTMLDivElement>) => void;
30
- onClick?: (e: React.MouseEvent<HTMLElement>) => void;
31
- invalid?: boolean;
32
- };
33
- //#endregion
34
- export { UnitPrimitiveProps };
package/lib/unit/types.js DELETED
File without changes
@@ -1,13 +0,0 @@
1
- import { ReactNode } from "react";
2
- //#region src/unit/unit-button-group.d.ts
3
- type Props = {
4
- big: boolean;
5
- inline: boolean;
6
- style: React.CSSProperties;
7
- className: string;
8
- unit?: ReactNode;
9
- navButton?: ReactNode;
10
- };
11
- declare const UnitButtonGroup: ({ big, inline, style, className, unit, navButton }: Props) => import("react/jsx-runtime").JSX.Element;
12
- //#endregion
13
- export { UnitButtonGroup };
@@ -1,23 +0,0 @@
1
- import { space } from "../design-system/layout.js";
2
- import { getHeight } from "./unit-content-layout.js";
3
- import { jsxs } from "react/jsx-runtime";
4
- import { Children, cloneElement } from "react";
5
- //#region src/unit/unit-button-group.tsx
6
- var UnitButtonGroup = ({ big, inline, style, className, unit, navButton }) => {
7
- const navButtonNode = navButton && Children.only(navButton);
8
- const navButtonSize = getHeight(big) + 2 * space.s2;
9
- return /* @__PURE__ */ jsxs("div", {
10
- style: {
11
- display: inline ? `inline-flex` : `flex`,
12
- ...style
13
- },
14
- className,
15
- children: [unit, navButtonNode && cloneElement(navButtonNode, { style: {
16
- ...navButtonNode.props.style,
17
- width: navButtonSize,
18
- height: navButtonSize
19
- } })]
20
- });
21
- };
22
- //#endregion
23
- export { UnitButtonGroup };