@shiflo/ui 0.0.3 → 0.0.4

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.
@@ -1,4 +1,4 @@
1
1
  import { default as Box } from './Box';
2
- import { BoxProps } from './Box.typing';
3
- export type { BoxProps };
2
+ import { BaseBoxProps, BoxProps } from './Box.typing';
3
+ export type { BaseBoxProps, BoxProps };
4
4
  export default Box;
@@ -1,5 +1,6 @@
1
1
  import { ComponentPropsWithRef, ReactNode } from 'react';
2
- export interface BaseButtonProps extends ComponentPropsWithRef<"button"> {
2
+ import { UtilityProps } from '../../typings/utility';
3
+ export interface BaseButtonProps extends Pick<UtilityProps, "css"> {
3
4
  size?: "xSmall" | "small" | "medium" | "large";
4
5
  startIcon?: ReactNode;
5
6
  endIcon?: ReactNode;
@@ -16,4 +17,4 @@ export interface TextButtonProps extends BaseButtonProps {
16
17
  variant?: "text";
17
18
  color?: "secondary";
18
19
  }
19
- export type ButtonProps = FilledButtonProps | GhostButtonProps | TextButtonProps;
20
+ export type ButtonProps = (FilledButtonProps | GhostButtonProps | TextButtonProps) & ComponentPropsWithRef<"button">;
@@ -1,4 +1,4 @@
1
1
  import { default as Button } from './Button';
2
- import { ButtonProps } from './Button.typing';
3
- export type { ButtonProps };
2
+ import { BaseButtonProps, ButtonProps } from './Button.typing';
3
+ export type { BaseButtonProps, ButtonProps };
4
4
  export default Button;
@@ -1,8 +1,9 @@
1
1
  import { ComponentPropsWithRef } from 'react';
2
- import { RecursionPath } from '../../typings/utility';
2
+ import { RecursionPath, UtilityProps } from '../../typings/utility';
3
3
  import { BasicTheme } from 'basic-styled';
4
4
  import type * as Svgs from "../../assets/icons";
5
- export interface IconProps extends Omit<ComponentPropsWithRef<"svg">, "children"> {
5
+ export interface BaseIconProps extends Pick<UtilityProps, "css"> {
6
6
  name: keyof typeof Svgs;
7
7
  color?: RecursionPath<BasicTheme["palette"]> | "inherit";
8
8
  }
9
+ export type IconProps = BaseIconProps & Omit<ComponentPropsWithRef<"svg">, "children">;
@@ -1,4 +1,4 @@
1
1
  import { default as Icon } from './Icon';
2
- import { IconProps } from './Icon.typing';
3
- export type { IconProps };
2
+ import { BaseIconProps, IconProps } from './Icon.typing';
3
+ export type { BaseIconProps, IconProps };
4
4
  export default Icon;
@@ -1,4 +1,5 @@
1
1
  import { ComponentPropsWithRef } from 'react';
2
- export interface TagProps extends ComponentPropsWithRef<"span"> {
2
+ import { UtilityProps } from '../../typings/utility';
3
+ export interface TagProps extends ComponentPropsWithRef<"span">, Pick<UtilityProps, "css"> {
3
4
  color?: "primary" | "warning" | "error" | "info" | "success";
4
5
  }
@@ -1,4 +1,4 @@
1
1
  import { default as Typography } from './Typography';
2
- import { TypographyProps } from './Typography.typing';
3
- export type { TypographyProps };
2
+ import { BaseTypographyProps, TypographyProps } from './Typography.typing';
3
+ export type { BaseTypographyProps, TypographyProps };
4
4
  export default Typography;
@@ -1,7 +1,7 @@
1
1
  import { jsxs as t, jsx as r } from "react/jsx-runtime";
2
2
  import m from "basic-styled/setup/createBuilder";
3
3
  import i from "basic-styled/setup/ResetStyle";
4
- import f from "/Users/x/WebstormProjects/shiflo-ui/node_modules/.pnpm/basic-styled@0.1.8_react-dom@19.0.0_react@19.0.0__react@19.0.0/node_modules/basic-styled/dist/setup/ThemeProvider.mjs";
4
+ import f from "basic-styled/setup/ThemeProvider";
5
5
  import l from "./dark.mjs";
6
6
  import p from "./GlobalStyle.mjs";
7
7
  import h from "./light.mjs";
@@ -1,7 +1,10 @@
1
+ import { CSS } from 'basic-styled/core/typing';
1
2
  import { default as radius } from '../theme/radius';
2
3
  import { default as spacing } from '../theme/spacing';
3
4
  import { Properties } from 'csstype';
4
- export type UtilityProps = Partial<Pick<Properties, "display" | "alignItems" | "justifyContent" | "flex" | "flexWrap" | "flexDirection" | "flexGrow" | "flexFlow" | "flexBasis" | "flexShrink" | "border" | "borderTop" | "borderBottom" | "borderRight" | "borderLeft"> & Record<"m" | "mt" | "mb" | "mr" | "ml" | "p" | "pt" | "pb" | "pl" | "pr" | "gap", keyof typeof spacing> & Record<"br" | "brtl" | "brtr" | "brml" | "brmr", keyof typeof radius>>;
5
+ export type UtilityProps = Partial<Pick<Properties, "display" | "alignItems" | "justifyContent" | "flex" | "flexWrap" | "flexDirection" | "flexGrow" | "flexFlow" | "flexBasis" | "flexShrink" | "border" | "borderTop" | "borderBottom" | "borderRight" | "borderLeft"> & Record<"m" | "mt" | "mb" | "mr" | "ml" | "p" | "pt" | "pb" | "pl" | "pr" | "gap", keyof typeof spacing> & Record<"br" | "brtl" | "brtr" | "brml" | "brmr", keyof typeof radius>> & {
6
+ css?: CSS;
7
+ };
5
8
  export type RecursionPath<T, Prefix extends string = ""> = Exclude<{
6
9
  [K in keyof T & (string | number)]: T[K] extends object ? `${Prefix}${K}` | RecursionPath<T[K], `${Prefix}${K}.`> : `${Prefix}${K}`;
7
10
  }[keyof T & (string | number)], "primary" | "secondary">;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@shiflo/ui",
3
3
  "description": "Shiflo React UI Components",
4
- "version": "0.0.3",
4
+ "version": "0.0.4",
5
5
  "type": "module",
6
6
  "files": [
7
7
  "dist"
@@ -85,7 +85,7 @@
85
85
  "vite-plugin-svgr": "^4.3.0"
86
86
  },
87
87
  "peerDependencies": {
88
- "basic-styled": ">=0.1.8",
88
+ "basic-styled": ">=0.1.10",
89
89
  "react": "^19.0.0",
90
90
  "react-dom": "^19.0.0"
91
91
  },
@@ -1 +0,0 @@
1
-
@@ -1 +0,0 @@
1
-