@saas-ui/react 3.0.0-alpha.18 → 3.0.0-alpha.19

Sign up to get free protection for your applications and to get access to all the features.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @saas-ui/react
2
2
 
3
+ ## 3.0.0-alpha.19
4
+
5
+ ### Patch Changes
6
+
7
+ - ba3b566: Improved Sidebar contrast
8
+ - 38082d4: Improved horizontal field styles
9
+ - ba3b566: Improved focusRing styles
10
+ - ba3b566: Added SegmentControl stories and made sizing consistent with buttons
11
+ - 3a73bc8: Fixed incorrect props type for GridListRoot
12
+ - ba3b566: Sidebar.Button now renders a div with role="button"
13
+ - 727b902: Allow click event on Sidebar.Track to be prevented
14
+
3
15
  ## 3.0.0-alpha.18
4
16
 
5
17
  ### Minor Changes
@@ -0,0 +1,8 @@
1
+ 'use client'
2
+
3
+ // src/components/icon-button/index.ts
4
+ import { IconButton } from "@chakra-ui/react";
5
+
6
+ export {
7
+ IconButton
8
+ };
@@ -18,7 +18,15 @@ var NumberInput = forwardRef(
18
18
  ...rest
19
19
  } = props;
20
20
  return /* @__PURE__ */ jsxs(ChakraNumberInput.Root, { ref: rootRef, ...rest, children: [
21
- /* @__PURE__ */ jsx(InputGroup, { startElement, endElement, children: /* @__PURE__ */ jsx(ChakraNumberInput.Input, { ref, ...inputProps }) }),
21
+ /* @__PURE__ */ jsx(
22
+ InputGroup,
23
+ {
24
+ startElement,
25
+ endElement,
26
+ width: "full",
27
+ children: /* @__PURE__ */ jsx(ChakraNumberInput.Input, { ref, ...inputProps })
28
+ }
29
+ ),
22
30
  !hideControls && !endElement ? /* @__PURE__ */ jsxs(ChakraNumberInput.Control, { children: [
23
31
  /* @__PURE__ */ jsx(ChakraNumberInput.IncrementTrigger, {}),
24
32
  /* @__PURE__ */ jsx(ChakraNumberInput.DecrementTrigger, {})
@@ -0,0 +1,31 @@
1
+ 'use client'
2
+ "use strict";
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
20
+
21
+ // src/components/card/index.ts
22
+ var card_exports = {};
23
+ __export(card_exports, {
24
+ Card: () => import_react.Card
25
+ });
26
+ module.exports = __toCommonJS(card_exports);
27
+ var import_react = require("@chakra-ui/react");
28
+ // Annotate the CommonJS export names for ESM import in node:
29
+ 0 && (module.exports = {
30
+ Card
31
+ });
@@ -0,0 +1 @@
1
+ export { Card } from '@chakra-ui/react';
@@ -0,0 +1 @@
1
+ export { Card } from '@chakra-ui/react';
@@ -0,0 +1,8 @@
1
+ 'use client'
2
+ import "../../chunk-RTMS5TJN.js";
3
+
4
+ // src/components/card/index.ts
5
+ import { Card } from "@chakra-ui/react";
6
+ export {
7
+ Card
8
+ };
@@ -1,10 +1,7 @@
1
1
  import * as react from 'react';
2
2
  import * as _chakra_ui_react from '@chakra-ui/react';
3
- import { RecipeProps as RecipeProps$1, RecipeDefinition, RecipeVariantProps, HTMLChakraProps, UnstyledProp } from '@chakra-ui/react';
4
-
5
- type RecipeProps<T, DefaultRecipe> = RecipeProps$1<T> extends {
6
- recipe?: RecipeDefinition;
7
- } ? RecipeProps$1<T> & DefaultRecipe : RecipeProps$1<T>;
3
+ import { RecipeVariantProps, HTMLChakraProps, UnstyledProp } from '@chakra-ui/react';
4
+ import { R as RecipeProps } from '../../types-DnFoUudY.cjs';
8
5
 
9
6
  declare const commandRecipe: _chakra_ui_react.RecipeDefinition<{
10
7
  size: {
@@ -1,10 +1,7 @@
1
1
  import * as react from 'react';
2
2
  import * as _chakra_ui_react from '@chakra-ui/react';
3
- import { RecipeProps as RecipeProps$1, RecipeDefinition, RecipeVariantProps, HTMLChakraProps, UnstyledProp } from '@chakra-ui/react';
4
-
5
- type RecipeProps<T, DefaultRecipe> = RecipeProps$1<T> extends {
6
- recipe?: RecipeDefinition;
7
- } ? RecipeProps$1<T> & DefaultRecipe : RecipeProps$1<T>;
3
+ import { RecipeVariantProps, HTMLChakraProps, UnstyledProp } from '@chakra-ui/react';
4
+ import { R as RecipeProps } from '../../types-DnFoUudY.js';
8
5
 
9
6
  declare const commandRecipe: _chakra_ui_react.RecipeDefinition<{
10
7
  size: {
@@ -1,10 +1,72 @@
1
1
  import * as react from 'react';
2
- import { HTMLChakraProps, SlotRecipeProps } from '@chakra-ui/react';
2
+ import * as _chakra_ui_react from '@chakra-ui/react';
3
+ import { RecipeVariantProps, HTMLChakraProps } from '@chakra-ui/react';
3
4
  import { GridList } from '@saas-ui/core/grid-list';
5
+ import { S as SlotRecipeProps } from '../../types-DnFoUudY.cjs';
4
6
 
5
- interface GridListRootProps extends GridList.RootProps, HTMLChakraProps<'div'>, SlotRecipeProps<'suiGridList'> {
7
+ declare const gridListSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"cell" | "root" | "item" | "header", {
8
+ interactive: {
9
+ true: {
10
+ item: {
11
+ cursor: "button";
12
+ transitionProperty: "bg";
13
+ transitionDuration: "fast";
14
+ _hover: {
15
+ bg: "bg.subtle";
16
+ };
17
+ _active: {
18
+ bg: "bg.subtle";
19
+ };
20
+ };
21
+ };
22
+ };
23
+ variant: {
24
+ simple: {};
25
+ rounded: {
26
+ item: {
27
+ borderRadius: "md";
28
+ mb: number;
29
+ };
30
+ };
31
+ };
32
+ size: {
33
+ sm: {
34
+ root: {
35
+ textStyle: "sm";
36
+ py: number;
37
+ };
38
+ item: {
39
+ py: number;
40
+ px: number;
41
+ gap: number;
42
+ };
43
+ header: {
44
+ py: number;
45
+ px: number;
46
+ };
47
+ };
48
+ md: {
49
+ root: {
50
+ textStyle: "md";
51
+ py: number;
52
+ };
53
+ item: {
54
+ py: number;
55
+ px: number;
56
+ gap: number;
57
+ };
58
+ header: {
59
+ py: number;
60
+ px: number;
61
+ };
62
+ };
63
+ };
64
+ }>;
65
+ type GridListVariantProps = RecipeVariantProps<typeof gridListSlotRecipe>;
66
+
67
+ interface GridListRootProps extends GridList.RootProps, HTMLChakraProps<'div'>, SlotRecipeProps<'suiGridList', GridListVariantProps> {
6
68
  }
7
- declare const GridListRoot: react.ForwardRefExoticComponent<GridList.RootProps & react.RefAttributes<HTMLDivElement>>;
69
+ declare const GridListRoot: react.ForwardRefExoticComponent<GridListRootProps & react.RefAttributes<HTMLDivElement>>;
8
70
  interface GridListItemProps extends GridList.ItemProps, HTMLChakraProps<'div'> {
9
71
  }
10
72
  declare const GridListItem: react.ForwardRefExoticComponent<GridListItemProps & react.RefAttributes<HTMLDivElement>>;
@@ -1,10 +1,72 @@
1
1
  import * as react from 'react';
2
- import { HTMLChakraProps, SlotRecipeProps } from '@chakra-ui/react';
2
+ import * as _chakra_ui_react from '@chakra-ui/react';
3
+ import { RecipeVariantProps, HTMLChakraProps } from '@chakra-ui/react';
3
4
  import { GridList } from '@saas-ui/core/grid-list';
5
+ import { S as SlotRecipeProps } from '../../types-DnFoUudY.js';
4
6
 
5
- interface GridListRootProps extends GridList.RootProps, HTMLChakraProps<'div'>, SlotRecipeProps<'suiGridList'> {
7
+ declare const gridListSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"cell" | "root" | "item" | "header", {
8
+ interactive: {
9
+ true: {
10
+ item: {
11
+ cursor: "button";
12
+ transitionProperty: "bg";
13
+ transitionDuration: "fast";
14
+ _hover: {
15
+ bg: "bg.subtle";
16
+ };
17
+ _active: {
18
+ bg: "bg.subtle";
19
+ };
20
+ };
21
+ };
22
+ };
23
+ variant: {
24
+ simple: {};
25
+ rounded: {
26
+ item: {
27
+ borderRadius: "md";
28
+ mb: number;
29
+ };
30
+ };
31
+ };
32
+ size: {
33
+ sm: {
34
+ root: {
35
+ textStyle: "sm";
36
+ py: number;
37
+ };
38
+ item: {
39
+ py: number;
40
+ px: number;
41
+ gap: number;
42
+ };
43
+ header: {
44
+ py: number;
45
+ px: number;
46
+ };
47
+ };
48
+ md: {
49
+ root: {
50
+ textStyle: "md";
51
+ py: number;
52
+ };
53
+ item: {
54
+ py: number;
55
+ px: number;
56
+ gap: number;
57
+ };
58
+ header: {
59
+ py: number;
60
+ px: number;
61
+ };
62
+ };
63
+ };
64
+ }>;
65
+ type GridListVariantProps = RecipeVariantProps<typeof gridListSlotRecipe>;
66
+
67
+ interface GridListRootProps extends GridList.RootProps, HTMLChakraProps<'div'>, SlotRecipeProps<'suiGridList', GridListVariantProps> {
6
68
  }
7
- declare const GridListRoot: react.ForwardRefExoticComponent<GridList.RootProps & react.RefAttributes<HTMLDivElement>>;
69
+ declare const GridListRoot: react.ForwardRefExoticComponent<GridListRootProps & react.RefAttributes<HTMLDivElement>>;
8
70
  interface GridListItemProps extends GridList.ItemProps, HTMLChakraProps<'div'> {
9
71
  }
10
72
  declare const GridListItem: react.ForwardRefExoticComponent<GridListItemProps & react.RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,31 @@
1
+ 'use client'
2
+ "use strict";
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
20
+
21
+ // src/components/icon-button/index.ts
22
+ var icon_button_exports = {};
23
+ __export(icon_button_exports, {
24
+ IconButton: () => import_react.IconButton
25
+ });
26
+ module.exports = __toCommonJS(icon_button_exports);
27
+ var import_react = require("@chakra-ui/react");
28
+ // Annotate the CommonJS export names for ESM import in node:
29
+ 0 && (module.exports = {
30
+ IconButton
31
+ });
@@ -0,0 +1 @@
1
+ export { IconButton, IconButtonProps } from '@chakra-ui/react';
@@ -0,0 +1 @@
1
+ export { IconButton, IconButtonProps } from '@chakra-ui/react';
@@ -0,0 +1,8 @@
1
+ 'use client'
2
+ import {
3
+ IconButton
4
+ } from "../../chunk-QVFJV6HJ.js";
5
+ import "../../chunk-RTMS5TJN.js";
6
+ export {
7
+ IconButton
8
+ };
@@ -68,7 +68,15 @@ var NumberInput = (0, import_react3.forwardRef)(
68
68
  ...rest
69
69
  } = props;
70
70
  return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_react4.NumberInput.Root, { ref: rootRef, ...rest, children: [
71
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(InputGroup, { startElement, endElement, children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react4.NumberInput.Input, { ref, ...inputProps }) }),
71
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
72
+ InputGroup,
73
+ {
74
+ startElement,
75
+ endElement,
76
+ width: "full",
77
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react4.NumberInput.Input, { ref, ...inputProps })
78
+ }
79
+ ),
72
80
  !hideControls && !endElement ? /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_react4.NumberInput.Control, { children: [
73
81
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react4.NumberInput.IncrementTrigger, {}),
74
82
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react4.NumberInput.DecrementTrigger, {})
@@ -1,7 +1,7 @@
1
1
  'use client'
2
2
  import {
3
3
  NumberInput
4
- } from "../../chunk-ULAJ3JEO.js";
4
+ } from "../../chunk-S5J6REMC.js";
5
5
  import "../../chunk-PKI6YH2V.js";
6
6
  import "../../chunk-RTMS5TJN.js";
7
7
  export {