@twintag/twintag-form 1.6.2 → 1.7.2

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 (54) hide show
  1. package/.turbo/turbo-build.log +16 -16
  2. package/CHANGELOG.md +24 -0
  3. package/dev/index.css +2 -2
  4. package/dev/main.tsx +1 -0
  5. package/dist/common/button.d.ts +0 -1
  6. package/dist/common/form.d.ts +0 -1
  7. package/dist/common/icon.d.ts +0 -1
  8. package/dist/common/input.d.ts +0 -1
  9. package/dist/common/label.d.ts +0 -1
  10. package/dist/common/textarea.d.ts +0 -1
  11. package/dist/components/config.d.ts +0 -1
  12. package/dist/components/containers/accordion.d.ts +1 -2
  13. package/dist/components/containers/category.d.ts +0 -1
  14. package/dist/components/fields/checkbox.d.ts +0 -1
  15. package/dist/components/fields/file.d.ts +0 -1
  16. package/dist/components/fields/input.d.ts +0 -1
  17. package/dist/components/fields/radiogroup.d.ts +0 -1
  18. package/dist/components/fields/submit.d.ts +0 -1
  19. package/dist/components/fields/textarea.d.ts +0 -1
  20. package/dist/components/fields/toggle.d.ts +0 -1
  21. package/dist/components/fields/tri-toggle.d.ts +0 -1
  22. package/dist/components/form.d.ts +0 -1
  23. package/dist/components/input.d.ts +0 -1
  24. package/dist/components/label.d.ts +0 -1
  25. package/dist/components/provider.d.ts +1 -2
  26. package/dist/index.cjs +1 -1
  27. package/dist/index.d.ts +0 -1
  28. package/dist/index.js +1437 -1601
  29. package/dist/types/index.d.ts +0 -1
  30. package/dist/utils/data.d.ts +0 -1
  31. package/dist/utils/style.d.ts +0 -1
  32. package/dist/webcomponent.cjs +1 -1
  33. package/dist/webcomponent.js +1118 -1104
  34. package/lib/common/icon.tsx +2 -1
  35. package/lib/components/config.tsx +1 -0
  36. package/lib/components/containers/accordion.tsx +3 -2
  37. package/lib/components/containers/category.tsx +1 -1
  38. package/lib/components/fields/checkbox.tsx +3 -6
  39. package/lib/components/fields/date-picker.tsx +3 -6
  40. package/lib/components/fields/file.tsx +3 -6
  41. package/lib/components/fields/input.tsx +3 -6
  42. package/lib/components/fields/radiogroup.tsx +3 -6
  43. package/lib/components/fields/submit.tsx +1 -0
  44. package/lib/components/fields/textarea.tsx +3 -6
  45. package/lib/components/fields/toggle.tsx +3 -6
  46. package/lib/components/fields/tri-toggle.tsx +3 -4
  47. package/lib/components/input.tsx +2 -1
  48. package/lib/components/label.tsx +1 -0
  49. package/lib/components/provider.tsx +2 -1
  50. package/lib/components/renderer.tsx +2 -1
  51. package/lib/index.tsx +1 -0
  52. package/package.json +10 -12
  53. package/prettier.config.mjs +1 -17
  54. package/vite.config.ts +1 -1
@@ -1,22 +1,22 @@
1
1
 
2
- > @twintag/twintag-form@1.6.2 build /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form
2
+ > @twintag/twintag-form@1.7.2 build /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form
3
3
  > tsc && vite build
4
4
 
5
- vite v5.4.8 building for production...
5
+ vite v7.3.2 building client environment for production...
6
6
  transforming...
7
- ✓ 49 modules transformed.
7
+ ✓ 57 modules transformed.
8
8
  rendering chunks...
9
-
10
- [vite:dts] Start generate declaration files...
9
+ 
10
+ [unplugin:dts] Start generate declaration files...
11
11
  computing gzip size...
12
- [vite:dts] Outside emitted: /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form/twind.config.d.ts
13
- dist/webcomponent.js  27.78 kB │ gzip: 5.51 kB
14
- dist/index.js 136.06 kB │ gzip: 28.76 kB
15
- [vite:dts] Outside emitted: /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form/tailwind.config.d.ts
16
- [vite:dts] Outside emitted: /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form/dev/main.d.ts
17
- [vite:dts] Outside emitted: /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form/vite.config.d.ts
18
- [vite:dts] Declaration files built in 9670ms.
19
-
20
- dist/webcomponent.cjs 18.82 kB │ gzip: 5.05 kB
21
- dist/index.cjs 95.08 kB │ gzip: 24.31 kB
22
- ✓ built in 10.52s
12
+ dist/webcomponent.js  30.19 kB │ gzip: 5.67 kB
13
+ dist/index.js 126.49 kB │ gzip: 26.38 kB
14
+ [unplugin:dts] Outside emitted: /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form/twind.config.d.ts
15
+ [unplugin:dts] Outside emitted: /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form/tailwind.config.d.ts
16
+ [unplugin:dts] Outside emitted: /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form/dev/main.d.ts
17
+ [unplugin:dts] Outside emitted: /home/runner/work/twintag-admin/twintag-admin/packages/twintag-form/vite.config.d.ts
18
+ [unplugin:dts] Declaration files built in 7534ms.
19
+ 
20
+ dist/webcomponent.cjs 18.98 kB │ gzip: 5.13 kB
21
+ dist/index.cjs 87.62 kB │ gzip: 22.14 kB
22
+ ✓ built in 8.39s
package/CHANGELOG.md CHANGED
@@ -1,5 +1,29 @@
1
1
  # @twintag/twintag-form
2
2
 
3
+ ## 1.7.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [#468](https://github.com/esoptra/twintag-admin/pull/468) [`864468e`](https://github.com/esoptra/twintag-admin/commit/864468ef5973f7e670ce7e37d29ea256a4f1265a) Thanks [@leweyse](https://github.com/leweyse)! - chore: update dependencies
8
+
9
+ ## 1.7.1
10
+
11
+ ### Patch Changes
12
+
13
+ - [#461](https://github.com/esoptra/twintag-admin/pull/461) [`977c0f6`](https://github.com/esoptra/twintag-admin/commit/977c0f6faff7f68533f84f3f1e58618cca396ac3) Thanks [@leweyse](https://github.com/leweyse)! - chore: update dependencies
14
+
15
+ ## 1.7.0
16
+
17
+ ### Minor Changes
18
+
19
+ - [#383](https://github.com/esoptra/twintag-admin/pull/383) [`e71f676`](https://github.com/esoptra/twintag-admin/commit/e71f67637790be606de86b271a98da7efbc7eab6) Thanks [@backkem](https://github.com/backkem)! - chore: React 19
20
+
21
+ ## 1.6.3
22
+
23
+ ### Patch Changes
24
+
25
+ - [#374](https://github.com/esoptra/twintag-admin/pull/374) [`8d66aa2`](https://github.com/esoptra/twintag-admin/commit/8d66aa219bea8ee3d284b91a04f315cbed5f0720) Thanks [@leweyse](https://github.com/leweyse)! - chore: update vulnerable dependencies
26
+
3
27
  ## 1.6.2
4
28
 
5
29
  ### Patch Changes
package/dev/index.css CHANGED
@@ -14,8 +14,8 @@
14
14
  --tf-muted: 210 40% 96.1%;
15
15
  --tf-muted-foreground: 215.4 16.3% 46.9%;
16
16
 
17
- --tf-primary: 210 40% 98%;
18
- --tf-primary-foreground: 222.2 47.4% 11.2%;
17
+ --tf-primary: 210 40% 98%;
18
+ --tf-primary-foreground: 222.2 47.4% 11.2%;
19
19
 
20
20
  --tf-accent: 222.2 47.4% 11.2%;
21
21
  --tf-accent-foreground: 210 40% 96.1%;
package/dev/main.tsx CHANGED
@@ -1,4 +1,5 @@
1
1
  import type { ComponentProps } from 'react';
2
+
2
3
  import type { Form } from '../lib';
3
4
 
4
5
  import '../lib/webcomponent';
@@ -1,5 +1,4 @@
1
1
  import { VariantProps, TVReturnType } from 'tailwind-variants';
2
-
3
2
  import * as React from 'react';
4
3
  declare const buttonVariants: TVReturnType<{
5
4
  variant: {
@@ -2,7 +2,6 @@ import { ControllerProps, FieldPath, FieldValues, FormProviderProps, FieldError
2
2
  import { VariantProps, TVReturnType } from 'tailwind-variants';
3
3
  import { LabelProps } from '@radix-ui/react-label';
4
4
  import { SlotProps } from '@radix-ui/react-slot';
5
-
6
5
  import * as React from 'react';
7
6
  declare const Form: <TFieldValues extends FieldValues, TContext = any, TTransformedValues = TFieldValues>(props: FormProviderProps<TFieldValues, TContext, TTransformedValues>) => React.JSX.Element;
8
7
  declare const FormField: <TFieldValues extends FieldValues = FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>({ ...props }: ControllerProps<TFieldValues, TName>) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
-
3
2
  type Props = {
4
3
  name: string;
5
4
  className?: string;
@@ -1,5 +1,4 @@
1
1
  import { VariantProps, TVReturnType } from 'tailwind-variants';
2
-
3
2
  import * as React from 'react';
4
3
  declare const inputVariants: TVReturnType<{
5
4
  variant: {
@@ -1,5 +1,4 @@
1
1
  import { VariantProps, TVReturnType } from 'tailwind-variants';
2
-
3
2
  import * as React from 'react';
4
3
  import * as LabelPrimitive from '@radix-ui/react-label';
5
4
  declare const Label: React.ForwardRefExoticComponent<Omit<LabelPrimitive.LabelProps & React.RefAttributes<HTMLLabelElement>, "ref"> & VariantProps< TVReturnType<{
@@ -1,5 +1,4 @@
1
1
  import { VariantProps, TVReturnType } from 'tailwind-variants';
2
-
3
2
  import * as React from 'react';
4
3
  declare const Textarea: React.ForwardRefExoticComponent<React.TextareaHTMLAttributes<HTMLTextAreaElement> & VariantProps< TVReturnType<{
5
4
  variant: {
@@ -1,6 +1,5 @@
1
1
  import { ElementType } from 'react';
2
2
  import { InputCompConfig } from '../types';
3
-
4
3
  export declare const Containers: Map<string, ElementType>;
5
4
  export declare const Inputs: Map<string, InputCompConfig>;
6
5
  export declare const components: Map<string, ElementType>;
@@ -1,7 +1,6 @@
1
1
  import { FC } from 'react';
2
- import { Props } from '../../types';
3
2
  import { WithChildren } from 'twintag-types/dom';
4
-
3
+ import { Props } from '../../types';
5
4
  type AccordionProps = Props<'accordion', 'item' | 'multiple' | 'single'> & WithChildren;
6
5
  declare const Accordion: FC<AccordionProps>;
7
6
  export { Accordion };
@@ -1,6 +1,5 @@
1
1
  import { FC } from 'react';
2
2
  import { WithChildren } from 'twintag-types/dom';
3
-
4
3
  type Props = {
5
4
  label?: string;
6
5
  } & WithChildren;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../../types';
3
-
4
3
  export declare const DEFAULT_CHECKBOX_VALUE = false;
5
4
  export declare const Checkbox: FC<Props<'input'>>;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../../types';
3
-
4
3
  export declare const DEFAULT_FILE_VALUE = "";
5
4
  export declare const File: FC<Props<'input', 'file'>>;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../../types';
3
-
4
3
  export declare const DEFAULT_INPUT_VALUE = "";
5
4
  export declare const Input: FC<Props<'input', 'text'>>;
@@ -1,6 +1,5 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../../types';
3
-
4
3
  export declare const DEFAULT_RADIOGROUP_VALUE = "";
5
4
  export declare const RadioGroup: FC<Props<'input'> & {
6
5
  items: Props<'input'>[];
@@ -1,4 +1,3 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../../types';
3
-
4
3
  export declare const Submit: FC<Props>;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../../types';
3
-
4
3
  export declare const DEFAULT_TEXTAREA_VALUE = "";
5
4
  export declare const Textarea: FC<Props<'input', 'text'>>;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../../types';
3
-
4
3
  export declare const DEFAULT_TOGGLE_VALUE = false;
5
4
  export declare const Toggle: FC<Props<'input'>>;
@@ -1,5 +1,4 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../../types';
3
-
4
3
  export declare const DEFAULT_TRI_TOGGLE_VALUE: null;
5
4
  export declare const TriToggle: FC<Props<'input'>>;
@@ -1,6 +1,5 @@
1
1
  import { FieldValues } from 'react-hook-form';
2
2
  import { ForwardRefExoticComponent, ReactNode, RefAttributes } from 'react';
3
-
4
3
  export declare const TwintagForm: ForwardRefExoticComponent<{
5
4
  defaultValues?: FieldValues;
6
5
  resetOnSubmit?: boolean;
@@ -1,4 +1,3 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../types';
3
-
4
3
  export declare const Input: FC<Props<'input'>>;
@@ -1,4 +1,3 @@
1
1
  import { FC } from 'react';
2
2
  import { Props } from '../types';
3
-
4
3
  export declare const Label: FC<Props>;
@@ -1,7 +1,6 @@
1
- import { ParsedJsonComponent, RawJsonComponent, TwintagFormContext } from '../types';
2
1
  import { WithChildren } from 'twintag-types/dom';
2
+ import { ParsedJsonComponent, RawJsonComponent, TwintagFormContext } from '../types';
3
3
  import { Context } from 'react';
4
-
5
4
  export declare const twintagFormContext: Context<TwintagFormContext>;
6
5
  export declare const useTwintagForm: () => TwintagFormContext;
7
6
  type Inputs = TwintagFormContext['inputs'];