Releases: sannajammeh/tw-classed
@tw-classed/core@1.3.2-canary.1
Patch Changes
-
091ef6a4
Thanks @sannajammeh! - Adds support in core lib forclass
&className
when calling a class producer functionExample:
const button = classed("bg-blue-500"); // LitHTML html`<button class=${button({ class: "text-white" })}>Click me</button>`;
@tw-classed/react@1.3.2-canary.0
Patch Changes
-
#65
df315431
Thanks @sannajammeh! - This patch adds support for Typescriptinteroperability
between the@tw-classed/core
and@tw-classed/react
packages. This makes it possible to use the@tw-classed/core
in a framework agnostic design system and then use the@tw-classed/react
in a React application.// Design system import { classed } from "@tw-classed/core"; export const button = classed({ base: "bg-blue-500 text-white", variants: { size: { sm: "px-2 py-1 text-sm", md: "px-3 py-2 text-base", lg: "px-4 py-3 text-lg", }, }, }); // React application import { button } from "design-system"; import { classed } from "@tw-classed/react"; export const Button = classed.button(button); // Variants are automatically inferred
@tw-classed/react@1.3.1
Patch Changes
4ffde042
Thanks @sannajammeh! - Export ClassedConfig type
@tw-classed/react@1.3.0
This release adds support for the createClassed
API to configure classed. Currently only the merger
prop is supported as config
You can build your own or use tailwind-merge
// Classed.config.ts
import { twMerge } from "tailwind-merge";
export const { classed } = createClassed({
merger: twMerge,
});
Minor Changes
- #52
47437bca
Thanks @sannajammeh! - Add createClassed API to extend the classed function with additional functionality. Currently only "merger" prop is supported
Patch Changes
-
#61
79be37a2
Thanks @sannajammeh! - This release extends core to support the createClassed API, adds improvements to the documentation -
#61
29570c7e
Thanks @sannajammeh! - Export DerivedComponentType to handle as prop in derived components -
#61
e7596bb9
Thanks @sannajammeh! - Fixes "This module is a CJS module" in node.js with type:"module" -
Updated dependencies [
79be37a2
,29570c7e
,f328e321
,e7596bb9
]:- @tw-classed/core@1.3.0
@tw-classed/core@1.3.0
Patch Changes
-
#61
79be37a2
Thanks @sannajammeh! - This release extends core to support the createClassed API, adds improvements to the documentation -
#61
29570c7e
Thanks @sannajammeh! - Export DerivedComponentType to handle as prop in derived components -
#61
f328e321
Thanks @sannajammeh! - Switch to SWC powered bunchee bundler -
#61
e7596bb9
Thanks @sannajammeh! - Fixes "This module is a CJS module" in node.js with type:"module"
@tw-classed/react@1.3.0-canary.4
Patch Changes
-
e7596bb9
Thanks @sannajammeh! - Fixes "This module is a CJS module" in node.js with type:"module" -
Updated dependencies [
e7596bb9
]:- @tw-classed/core@1.3.0-canary.4
@tw-classed/core@1.3.0-canary.4
Patch Changes
e7596bb9
Thanks @sannajammeh! - Fixes "This module is a CJS module" in node.js with type:"module"
@tw-classed/react@1.3.0-canary.3
Patch Changes
- Updated dependencies [
f328e321
]:- @tw-classed/core@1.3.0-canary.3
@tw-classed/react@1.3.0-canary.2
Patch Changes
-
29570c7e
Thanks @sannajammeh! - Export DerivedComponentType to handle as prop in derived components -
Updated dependencies [
29570c7e
]:- @tw-classed/core@1.3.0-canary.2
@tw-classed/core@1.3.0-canary.3
Patch Changes
f328e321
Thanks @sannajammeh! - Switch to SWC powered bunchee bundler