@heliosgraphics/ui 2.0.0-alpha.93 → 2.0.0-alpha.94

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 (56) hide show
  1. package/components/Breadcrumb/Breadcrumb.tsx +25 -23
  2. package/components/Button/Button.tsx +172 -174
  3. package/components/Checkbox/Checkbox.tsx +54 -60
  4. package/components/Confirm/Confirm.tsx +1 -1
  5. package/components/Dialog/Dialog.meta.ts +4 -0
  6. package/components/Dialog/Dialog.tsx +11 -2
  7. package/components/Dialog/Dialog.types.ts +1 -0
  8. package/components/Donut/Donut.tsx +1 -0
  9. package/components/Dropdown/Dropdown.tsx +6 -1
  10. package/components/Flex/Flex.meta.ts +2 -0
  11. package/components/Flex/Flex.tsx +2 -3
  12. package/components/Flex/Flex.types.ts +3 -1
  13. package/components/Flex/Flex.utils.ts +36 -1
  14. package/components/Flex/index.ts +0 -2
  15. package/components/Heading/Heading.tsx +3 -3
  16. package/components/Icon/Icon.tsx +3 -3
  17. package/components/Input/Input.tsx +5 -2
  18. package/components/Layout/components/LayoutAside/components/LayoutAsideContent/LayoutAsideContent.tsx +0 -2
  19. package/components/Layout/components/LayoutAside/components/LayoutAsideFooter/LayoutAsideFooter.tsx +0 -2
  20. package/components/Loading/Loading.tsx +8 -4
  21. package/components/Masonry/Masonry.meta.ts +1 -5
  22. package/components/Masonry/Masonry.tsx +27 -14
  23. package/components/Masonry/Masonry.types.ts +4 -4
  24. package/components/Overlay/Overlay.tsx +1 -1
  25. package/components/Pie/Pie.tsx +1 -0
  26. package/components/Progress/Progress.meta.ts +4 -0
  27. package/components/Progress/Progress.tsx +8 -2
  28. package/components/Progress/Progress.types.ts +1 -0
  29. package/components/Radio/Radio.tsx +57 -63
  30. package/components/Range/Range.meta.ts +26 -0
  31. package/components/Range/Range.module.css +68 -0
  32. package/components/Range/Range.tsx +47 -0
  33. package/components/Range/Range.types.ts +13 -0
  34. package/components/Range/index.ts +1 -0
  35. package/components/Select/Select.meta.ts +4 -0
  36. package/components/Select/Select.tsx +2 -0
  37. package/components/Select/Select.types.ts +1 -0
  38. package/components/Separator/Separator.tsx +25 -20
  39. package/components/Separator/components/VerticalSeparator/VerticalSeparator.tsx +1 -1
  40. package/components/Setup/Setup.tsx +0 -13
  41. package/components/Setup/css/feat.responsive.css +402 -0
  42. package/components/Slider/Slider.meta.ts +4 -0
  43. package/components/Slider/Slider.tsx +2 -2
  44. package/components/Slider/Slider.types.ts +1 -0
  45. package/components/Spacer/Spacer.tsx +3 -3
  46. package/components/Tabs/Tabs.tsx +14 -3
  47. package/components/Text/Text.tsx +3 -3
  48. package/components/Tile/Tile.tsx +10 -1
  49. package/components/Tooltip/Tooltip.tsx +3 -1
  50. package/components/Tooltip/Tooltip.types.ts +1 -0
  51. package/components/Tooltip/components/TooltipContent/TooltipContent.tsx +9 -2
  52. package/components/Tooltip/components/TooltipTrigger/TooltipTrigger.tsx +2 -2
  53. package/constants/components.ts +2 -0
  54. package/globals.d.ts +12 -0
  55. package/index.ts +1 -0
  56. package/package.json +6 -5
@@ -4,12 +4,19 @@ import type { CSSProperties, FC } from "react"
4
4
  import type { TooltipContentProps } from "./TooltipContent.types"
5
5
 
6
6
  export const TooltipContent: FC<TooltipContentProps> = ({ children }) => {
7
- const { popoverRef, tooltipClasses, anchorName } = useTooltipContext()
7
+ const { popoverRef, tooltipClasses, anchorName, tooltipId } = useTooltipContext()
8
8
 
9
9
  const contentStyle: CSSProperties = { positionAnchor: anchorName } as CSSProperties
10
10
 
11
11
  return (
12
- <div className={tooltipClasses} ref={popoverRef} popover="manual" style={contentStyle}>
12
+ <div
13
+ id={tooltipId}
14
+ role="tooltip"
15
+ className={tooltipClasses}
16
+ ref={popoverRef}
17
+ popover="manual"
18
+ style={contentStyle}
19
+ >
13
20
  <Text type="small">{children}</Text>
14
21
  </div>
15
22
  )
@@ -3,12 +3,12 @@ import { useTooltipContext } from "../../Tooltip.utils"
3
3
  import type { CSSProperties, FC } from "react"
4
4
 
5
5
  export const TooltipTrigger: FC<TooltipTriggerProps> = ({ children }) => {
6
- const { triggerRef, anchorName } = useTooltipContext()
6
+ const { triggerRef, anchorName, tooltipId, isOpen } = useTooltipContext()
7
7
 
8
8
  const triggerStyle: CSSProperties = { anchorName } as CSSProperties
9
9
 
10
10
  return (
11
- <div ref={triggerRef} style={triggerStyle}>
11
+ <div ref={triggerRef} style={triggerStyle} aria-describedby={isOpen ? tooltipId : undefined}>
12
12
  {children}
13
13
  </div>
14
14
  )
@@ -32,6 +32,7 @@ import { meta as metaPie } from "../components/Pie/Pie.meta"
32
32
  import { meta as metaPill } from "../components/Pill/Pill.meta"
33
33
  import { meta as metaProgress } from "../components/Progress/Progress.meta"
34
34
  import { meta as metaRadio } from "../components/Radio/Radio.meta"
35
+ import { meta as metaRange } from "../components/Range/Range.meta"
35
36
  import { meta as metaSegments } from "../components/Segments/Segments.meta"
36
37
  import { meta as metaSelect } from "../components/Select/Select.meta"
37
38
  import { meta as metaSeparator } from "../components/Separator/Separator.meta"
@@ -81,6 +82,7 @@ export const COMPONENTS: Record<string, HeliosAttributeMeta<unknown>> = {
81
82
  Pill: metaPill,
82
83
  Progress: metaProgress,
83
84
  Radio: metaRadio,
85
+ Range: metaRange,
84
86
  Segments: metaSegments,
85
87
  Select: metaSelect,
86
88
  Separator: metaSeparator,
package/globals.d.ts CHANGED
@@ -1,2 +1,14 @@
1
1
  declare module "*.module.css"
2
2
  declare module "*.css"
3
+
4
+ type HeliosFixedThemeTypeRef = import("./types/themes").HeliosFixedThemeType
5
+
6
+ interface Window {
7
+ __theme: HeliosFixedThemeTypeRef
8
+ __onThemeChange: ((theme: HeliosFixedThemeTypeRef) => void) | undefined
9
+ __setPreferredTheme: (theme: HeliosFixedThemeTypeRef) => void
10
+ }
11
+
12
+ declare var __theme: HeliosFixedThemeTypeRef
13
+ declare var __onThemeChange: ((theme: HeliosFixedThemeTypeRef) => void) | undefined
14
+ declare var __setPreferredTheme: (theme: HeliosFixedThemeTypeRef) => void
package/index.ts CHANGED
@@ -34,6 +34,7 @@ export { Pill } from "./components/Pill"
34
34
  export { Placeholder } from "./components/Placeholder"
35
35
  export { Progress } from "./components/Progress"
36
36
  export { Radio } from "./components/Radio"
37
+ export { Range } from "./components/Range"
37
38
  export { Segments } from "./components/Segments"
38
39
  export { Select } from "./components/Select"
39
40
  export { Separator } from "./components/Separator"
package/package.json CHANGED
@@ -1,8 +1,11 @@
1
1
  {
2
2
  "name": "@heliosgraphics/ui",
3
- "version": "2.0.0-alpha.93",
3
+ "version": "2.0.0-alpha.94",
4
4
  "type": "module",
5
- "sideEffects": false,
5
+ "sideEffects": [
6
+ "*.css",
7
+ "*.module.css"
8
+ ],
6
9
  "author": "Chris Puska <chris@puska.org>",
7
10
  "private": false,
8
11
  "description": "Helios UI",
@@ -42,11 +45,9 @@
42
45
  "@heliosgraphics/css": "^1.0.0-alpha.5",
43
46
  "@heliosgraphics/icons": "^1.0.0-alpha.11",
44
47
  "@heliosgraphics/utils": "^6.0.0-alpha.9",
45
- "dayjs": "^1.11.19",
46
48
  "marked": "^17.0.2",
47
49
  "marked-linkify-it": "^3.1.14",
48
- "marked-xhtml": "^1.0.14",
49
- "react-plock": "^3.6.1"
50
+ "marked-xhtml": "^1.0.14"
50
51
  },
51
52
  "devDependencies": {
52
53
  "@testing-library/react": "^16.3.2",