@ttoss/ui 1.22.0 → 1.23.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.
package/dist/esm/index.js CHANGED
@@ -186,10 +186,12 @@ import { Radio } from "theme-ui";
186
186
  // src/components/Icon/Icon.tsx
187
187
  import { Icon as IconUI } from "@iconify/react";
188
188
  import { jsx as jsx3 } from "react/jsx-runtime";
189
- var Icon = ({ icon, sx }) => {
189
+ var Icon = ({ icon, sx, iconProps, ...props }) => {
190
190
  return /* @__PURE__ */ jsx3(Text, {
191
191
  sx,
192
+ ...props,
192
193
  children: /* @__PURE__ */ jsx3(IconUI, {
194
+ ...iconProps,
193
195
  icon
194
196
  })
195
197
  });
@@ -197,10 +199,14 @@ var Icon = ({ icon, sx }) => {
197
199
 
198
200
  // src/components/Slider/Slider.tsx
199
201
  import { Slider } from "theme-ui";
202
+
203
+ // src/components/Checkbox/Checkbox.tsx
204
+ import { Checkbox } from "theme-ui";
200
205
  export {
201
206
  Box,
202
207
  Button,
203
208
  Card,
209
+ Checkbox,
204
210
  Divider,
205
211
  Flex,
206
212
  Grid,
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as theme_ui from 'theme-ui';
2
2
  import { Theme, ButtonProps, TextProps } from 'theme-ui';
3
- export { Box, BoxProps, ButtonProps, Card, CardProps, Divider, DividerProps, Flex, FlexProps, Grid, GridProps, Heading, HeadingProps, Image, ImageProps, Input, InputProps, Label, LabelProps, Progress as LinearProgress, ProgressProps as LinearProgressProps, Link, LinkProps, Radio, RadioProps, Select, SelectProps, Slider, SliderProps, Spinner, SpinnerProps, Text, TextProps, Theme } from 'theme-ui';
3
+ export { Box, BoxProps, ButtonProps, Card, CardProps, Checkbox, CheckboxProps, Divider, DividerProps, Flex, FlexProps, Grid, GridProps, Heading, HeadingProps, Image, ImageProps, Input, InputProps, Label, LabelProps, Progress as LinearProgress, ProgressProps as LinearProgressProps, Link, LinkProps, Radio, RadioProps, Select, SelectProps, Slider, SliderProps, Spinner, SpinnerProps, Text, TextProps, Theme } from 'theme-ui';
4
4
  export { useBreakpointIndex, useResponsiveValue } from '@theme-ui/match-media';
5
5
  import * as React from 'react';
6
6
  import { IconProps as IconProps$1 } from '@iconify/react';
@@ -19,10 +19,10 @@ declare const useTheme: () => theme_ui.ThemeUIContextValue;
19
19
 
20
20
  declare const Button: (props: ButtonProps) => JSX.Element;
21
21
 
22
- declare type IconProps = {
22
+ declare type IconProps = TextProps & {
23
23
  icon: IconProps$1['icon'];
24
- sx?: TextProps['sx'];
24
+ iconProps?: Omit<IconProps$1, 'icon'>;
25
25
  };
26
- declare const Icon: ({ icon, sx }: IconProps) => JSX.Element;
26
+ declare const Icon: ({ icon, sx, iconProps, ...props }: IconProps) => JSX.Element;
27
27
 
28
28
  export { Button, Icon, IconProps, ThemeProvider, ThemeProviderProps, useTheme };
package/dist/index.js CHANGED
@@ -30,6 +30,7 @@ __export(src_exports, {
30
30
  Box: () => import_theme_ui3.Box,
31
31
  Button: () => Button,
32
32
  Card: () => import_theme_ui5.Card,
33
+ Checkbox: () => import_theme_ui20.Checkbox,
33
34
  Divider: () => import_theme_ui6.Divider,
34
35
  Flex: () => import_theme_ui7.Flex,
35
36
  Grid: () => import_theme_ui8.Grid,
@@ -236,10 +237,12 @@ var import_theme_ui18 = require("theme-ui");
236
237
  // src/components/Icon/Icon.tsx
237
238
  var import_react2 = require("@iconify/react");
238
239
  var import_jsx_runtime3 = require("react/jsx-runtime");
239
- var Icon = ({ icon, sx }) => {
240
+ var Icon = ({ icon, sx, iconProps, ...props }) => {
240
241
  return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_theme_ui15.Text, {
241
242
  sx,
243
+ ...props,
242
244
  children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react2.Icon, {
245
+ ...iconProps,
243
246
  icon
244
247
  })
245
248
  });
@@ -247,11 +250,15 @@ var Icon = ({ icon, sx }) => {
247
250
 
248
251
  // src/components/Slider/Slider.tsx
249
252
  var import_theme_ui19 = require("theme-ui");
253
+
254
+ // src/components/Checkbox/Checkbox.tsx
255
+ var import_theme_ui20 = require("theme-ui");
250
256
  // Annotate the CommonJS export names for ESM import in node:
251
257
  0 && (module.exports = {
252
258
  Box,
253
259
  Button,
254
260
  Card,
261
+ Checkbox,
255
262
  Divider,
256
263
  Flex,
257
264
  Grid,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ttoss/ui",
3
- "version": "1.22.0",
3
+ "version": "1.23.1",
4
4
  "description": "Primitive layout, typographic, and other components for styling applications.",
5
5
  "license": "UNLICENSED",
6
6
  "author": "ttoss",
@@ -45,5 +45,5 @@
45
45
  "publishConfig": {
46
46
  "access": "public"
47
47
  },
48
- "gitHead": "d1583c4306e792373d84030dba29f9e6cc57031d"
48
+ "gitHead": "e9c6b47f9b2ff9a44358a16c9feff84ba9342346"
49
49
  }
@@ -0,0 +1 @@
1
+ export { Checkbox, type CheckboxProps } from 'theme-ui';
@@ -1,15 +1,15 @@
1
1
  import { IconProps as IconPropsUI, Icon as IconUI } from '@iconify/react';
2
2
  import { Text, TextProps } from '../Text/Text';
3
3
 
4
- export type IconProps = {
4
+ export type IconProps = TextProps & {
5
5
  icon: IconPropsUI['icon'];
6
- sx?: TextProps['sx'];
6
+ iconProps?: Omit<IconPropsUI, 'icon'>;
7
7
  };
8
8
 
9
- export const Icon = ({ icon, sx }: IconProps) => {
9
+ export const Icon = ({ icon, sx, iconProps, ...props }: IconProps) => {
10
10
  return (
11
- <Text sx={sx}>
12
- <IconUI icon={icon} />
11
+ <Text sx={sx} {...props}>
12
+ <IconUI {...iconProps} icon={icon} />
13
13
  </Text>
14
14
  );
15
15
  };
package/src/index.ts CHANGED
@@ -29,3 +29,4 @@ export { Spinner, type SpinnerProps } from './components/Spinner/Spinner';
29
29
  export { Radio, type RadioProps } from './components/Radio/Radio';
30
30
  export { Icon, type IconProps } from './components/Icon/Icon';
31
31
  export { Slider, type SliderProps } from './components/Slider/Slider';
32
+ export { Checkbox, type CheckboxProps } from './components/Checkbox/Checkbox';