Skip to content

Commit

Permalink
switch from \r\n to \n
Browse files Browse the repository at this point in the history
  • Loading branch information
stefan-karger committed Dec 15, 2023
1 parent bf2dc0e commit 6c935ed
Show file tree
Hide file tree
Showing 40 changed files with 49 additions and 44 deletions.
6 changes: 6 additions & 0 deletions .changeset/chilled-pumas-push.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"solidui-cli": minor
"docs": patch
---

switch from windows linebreaks (\r\n) to unix linebreaks (\n)
9 changes: 3 additions & 6 deletions apps/docs/public/registry/ui/accordion.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
{
"name": "accordion",
"dependencies": [
"@kobalte/core",
"solid-icons"
],
"dependencies": ["@kobalte/core", "solid-icons"],
"files": [
{
"name": "accordion.tsx",
"content": "import type { Component } from \"solid-js\"\r\nimport { splitProps } from \"solid-js\"\r\n\r\nimport { Accordion as AccordionPrimitive } from \"@kobalte/core\"\r\nimport { TbChevronDown } from \"solid-icons/tb\"\r\n\r\nimport { cn } from \"~/lib/utils\"\r\n\r\nconst Accordion = AccordionPrimitive.Root\r\n\r\nconst AccordionItem: Component<AccordionPrimitive.AccordionItemProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return <AccordionPrimitive.Item class={cn(\"border-b\", props.class)} {...rest} />\r\n}\r\n\r\nconst AccordionTrigger: Component<AccordionPrimitive.AccordionTriggerProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\", \"children\"])\r\n return (\r\n <AccordionPrimitive.Header class=\"flex\">\r\n <AccordionPrimitive.Trigger\r\n class={cn(\r\n \"flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-expanded]>svg]:rotate-180\",\r\n props.class\r\n )}\r\n {...rest}\r\n >\r\n {props.children}\r\n <TbChevronDown class=\"h-4 w-4 shrink-0 transition-transform duration-200\" />\r\n </AccordionPrimitive.Trigger>\r\n </AccordionPrimitive.Header>\r\n )\r\n}\r\n\r\nconst AccordionContent: Component<AccordionPrimitive.AccordionContentProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\", \"children\"])\r\n return (\r\n <AccordionPrimitive.Content\r\n class={cn(\r\n \"animate-accordion-up data-[expanded]:animate-accordion-down overflow-hidden text-sm transition-all\",\r\n props.class\r\n )}\r\n {...rest}\r\n >\r\n <div class=\"pb-4 pt-0\">{props.children}</div>\r\n </AccordionPrimitive.Content>\r\n )\r\n}\r\n\r\nexport { Accordion, AccordionItem, AccordionTrigger, AccordionContent }\r\n"
"content": "import type { Component } from \"solid-js\"\nimport { splitProps } from \"solid-js\"\n\nimport { Accordion as AccordionPrimitive } from \"@kobalte/core\"\nimport { TbChevronDown } from \"solid-icons/tb\"\n\nimport { cn } from \"~/lib/utils\"\n\nconst Accordion = AccordionPrimitive.Root\n\nconst AccordionItem: Component<AccordionPrimitive.AccordionItemProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\"])\n return <AccordionPrimitive.Item class={cn(\"border-b\", props.class)} {...rest} />\n}\n\nconst AccordionTrigger: Component<AccordionPrimitive.AccordionTriggerProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\", \"children\"])\n return (\n <AccordionPrimitive.Header class=\"flex\">\n <AccordionPrimitive.Trigger\n class={cn(\n \"flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-expanded]>svg]:rotate-180\",\n props.class\n )}\n {...rest}\n >\n {props.children}\n <TbChevronDown class=\"h-4 w-4 shrink-0 transition-transform duration-200\" />\n </AccordionPrimitive.Trigger>\n </AccordionPrimitive.Header>\n )\n}\n\nconst AccordionContent: Component<AccordionPrimitive.AccordionContentProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\", \"children\"])\n return (\n <AccordionPrimitive.Content\n class={cn(\n \"animate-accordion-up data-[expanded]:animate-accordion-down overflow-hidden text-sm transition-all\",\n props.class\n )}\n {...rest}\n >\n <div class=\"pb-4 pt-0\">{props.children}</div>\n </AccordionPrimitive.Content>\n )\n}\n\nexport { Accordion, AccordionItem, AccordionTrigger, AccordionContent }\n"
}
],
"type": "ui"
}
}
2 changes: 1 addition & 1 deletion apps/docs/public/registry/ui/alert-dialog.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"files": [
{
"name": "alert-dialog.tsx",
"content": "import type { Component } from \"solid-js\"\r\nimport { splitProps } from \"solid-js\"\r\n\r\nimport { AlertDialog as AlertDialogPrimitive } from \"@kobalte/core\"\r\nimport { TbX } from \"solid-icons/tb\"\r\n\r\nimport { cn } from \"~/lib/utils\"\r\n\r\nconst AlertDialog = AlertDialogPrimitive.Root\r\nconst AlertDialogTrigger = AlertDialogPrimitive.Trigger\r\nconst AlertDialogPortal = AlertDialogPrimitive.Portal\r\n\r\nconst AlertDialogOverlay: Component<AlertDialogPrimitive.AlertDialogOverlayProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return (\r\n <AlertDialogPrimitive.Overlay\r\n class={cn(\r\n \"bg-background/80 data-[expanded]:animate-in data-[closed]:animate-out data-[closed]:fade-out-0 data-[expanded]:fade-in-0 fixed inset-0 z-50 backdrop-blur-sm\",\r\n props.class\r\n )}\r\n {...rest}\r\n />\r\n )\r\n}\r\n\r\nconst AlertDialogContent: Component<AlertDialogPrimitive.AlertDialogContentProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\", \"children\"])\r\n return (\r\n <AlertDialogPortal>\r\n <AlertDialogOverlay />\r\n <AlertDialogPrimitive.Content\r\n class={cn(\r\n \"bg-background data-[expanded]:animate-in data-[closed]:animate-out data-[closed]:fade-out-0 data-[expanded]:fade-in-0 data-[closed]:zoom-out-95 data-[expanded]:zoom-in-95 data-[closed]:slide-out-to-left-1/2 data-[closed]:slide-out-to-top-[48%] data-[expanded]:slide-in-from-left-1/2 data-[expanded]:slide-in-from-top-[48%] fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border p-6 shadow-lg duration-200 sm:rounded-lg md:w-full\",\r\n props.class\r\n )}\r\n {...rest}\r\n >\r\n {props.children}\r\n <AlertDialogPrimitive.CloseButton class=\"ring-offset-background focus:ring-ring data-[expanded]:bg-accent data-[expanded]:text-muted-foreground absolute right-4 top-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:pointer-events-none\">\r\n <TbX class=\"h-4 w-4\" />\r\n <span class=\"sr-only\">Close</span>\r\n </AlertDialogPrimitive.CloseButton>\r\n </AlertDialogPrimitive.Content>\r\n </AlertDialogPortal>\r\n )\r\n}\r\n\r\nconst AlertDialogTitle: Component<AlertDialogPrimitive.AlertDialogTitleProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return <AlertDialogPrimitive.Title class={cn(\"text-lg font-semibold\", props.class)} {...rest} />\r\n}\r\n\r\nconst AlertDialogDescription: Component<AlertDialogPrimitive.AlertDialogDescriptionProps> = (\r\n props\r\n) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return (\r\n <AlertDialogPrimitive.Description\r\n class={cn(\"text-muted-foreground text-sm\", props.class)}\r\n {...rest}\r\n />\r\n )\r\n}\r\n\r\nexport {\r\n AlertDialog,\r\n AlertDialogPortal,\r\n AlertDialogOverlay,\r\n AlertDialogTrigger,\r\n AlertDialogContent,\r\n AlertDialogTitle,\r\n AlertDialogDescription\r\n}\r\n"
"content": "import type { Component } from \"solid-js\"\nimport { splitProps } from \"solid-js\"\n\nimport { AlertDialog as AlertDialogPrimitive } from \"@kobalte/core\"\nimport { TbX } from \"solid-icons/tb\"\n\nimport { cn } from \"~/lib/utils\"\n\nconst AlertDialog = AlertDialogPrimitive.Root\nconst AlertDialogTrigger = AlertDialogPrimitive.Trigger\nconst AlertDialogPortal = AlertDialogPrimitive.Portal\n\nconst AlertDialogOverlay: Component<AlertDialogPrimitive.AlertDialogOverlayProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\"])\n return (\n <AlertDialogPrimitive.Overlay\n class={cn(\n \"bg-background/80 data-[expanded]:animate-in data-[closed]:animate-out data-[closed]:fade-out-0 data-[expanded]:fade-in-0 fixed inset-0 z-50 backdrop-blur-sm\",\n props.class\n )}\n {...rest}\n />\n )\n}\n\nconst AlertDialogContent: Component<AlertDialogPrimitive.AlertDialogContentProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\", \"children\"])\n return (\n <AlertDialogPortal>\n <AlertDialogOverlay />\n <AlertDialogPrimitive.Content\n class={cn(\n \"bg-background data-[expanded]:animate-in data-[closed]:animate-out data-[closed]:fade-out-0 data-[expanded]:fade-in-0 data-[closed]:zoom-out-95 data-[expanded]:zoom-in-95 data-[closed]:slide-out-to-left-1/2 data-[closed]:slide-out-to-top-[48%] data-[expanded]:slide-in-from-left-1/2 data-[expanded]:slide-in-from-top-[48%] fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border p-6 shadow-lg duration-200 sm:rounded-lg md:w-full\",\n props.class\n )}\n {...rest}\n >\n {props.children}\n <AlertDialogPrimitive.CloseButton class=\"ring-offset-background focus:ring-ring data-[expanded]:bg-accent data-[expanded]:text-muted-foreground absolute right-4 top-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:pointer-events-none\">\n <TbX class=\"h-4 w-4\" />\n <span class=\"sr-only\">Close</span>\n </AlertDialogPrimitive.CloseButton>\n </AlertDialogPrimitive.Content>\n </AlertDialogPortal>\n )\n}\n\nconst AlertDialogTitle: Component<AlertDialogPrimitive.AlertDialogTitleProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\"])\n return <AlertDialogPrimitive.Title class={cn(\"text-lg font-semibold\", props.class)} {...rest} />\n}\n\nconst AlertDialogDescription: Component<AlertDialogPrimitive.AlertDialogDescriptionProps> = (\n props\n) => {\n const [, rest] = splitProps(props, [\"class\"])\n return (\n <AlertDialogPrimitive.Description\n class={cn(\"text-muted-foreground text-sm\", props.class)}\n {...rest}\n />\n )\n}\n\nexport {\n AlertDialog,\n AlertDialogPortal,\n AlertDialogOverlay,\n AlertDialogTrigger,\n AlertDialogContent,\n AlertDialogTitle,\n AlertDialogDescription\n}\n"
}
],
"type": "ui"
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/public/registry/ui/alert.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"files": [
{
"name": "alert.tsx",
"content": "import type { Component, ComponentProps } from \"solid-js\"\r\nimport { splitProps } from \"solid-js\"\r\n\r\nimport { Alert as AlertPrimitive } from \"@kobalte/core\"\r\nimport type { VariantProps } from \"class-variance-authority\"\r\nimport { cva } from \"class-variance-authority\"\r\n\r\nimport { cn } from \"~/lib/utils\"\r\n\r\nconst alertVariants = cva(\r\n \"[&>svg]:text-foreground relative w-full rounded-lg border p-4 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7\",\r\n {\r\n variants: {\r\n variant: {\r\n default: \"bg-background text-foreground\",\r\n destructive:\r\n \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\"\r\n }\r\n },\r\n defaultVariants: {\r\n variant: \"default\"\r\n }\r\n }\r\n)\r\n\r\ninterface AlertProps extends AlertPrimitive.AlertRootProps, VariantProps<typeof alertVariants> {}\r\n\r\nconst Alert: Component<AlertProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\", \"variant\"])\r\n return (\r\n <AlertPrimitive.Root\r\n class={cn(alertVariants({ variant: props.variant }), props.class)}\r\n {...rest}\r\n />\r\n )\r\n}\r\n\r\nconst AlertTitle: Component<ComponentProps<\"h5\">> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return <h5 class={cn(\"mb-1 font-medium leading-none tracking-tight\", props.class)} {...rest} />\r\n}\r\n\r\nconst AlertDescription: Component<ComponentProps<\"div\">> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return <div class={cn(\"text-sm [&_p]:leading-relaxed\", props.class)} {...rest} />\r\n}\r\n\r\nexport { Alert, AlertTitle, AlertDescription }\r\n"
"content": "import type { Component, ComponentProps } from \"solid-js\"\nimport { splitProps } from \"solid-js\"\n\nimport { Alert as AlertPrimitive } from \"@kobalte/core\"\nimport type { VariantProps } from \"class-variance-authority\"\nimport { cva } from \"class-variance-authority\"\n\nimport { cn } from \"~/lib/utils\"\n\nconst alertVariants = cva(\n \"[&>svg]:text-foreground relative w-full rounded-lg border p-4 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg~*]:pl-7\",\n {\n variants: {\n variant: {\n default: \"bg-background text-foreground\",\n destructive:\n \"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive\"\n }\n },\n defaultVariants: {\n variant: \"default\"\n }\n }\n)\n\ninterface AlertProps extends AlertPrimitive.AlertRootProps, VariantProps<typeof alertVariants> {}\n\nconst Alert: Component<AlertProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\", \"variant\"])\n return (\n <AlertPrimitive.Root\n class={cn(alertVariants({ variant: props.variant }), props.class)}\n {...rest}\n />\n )\n}\n\nconst AlertTitle: Component<ComponentProps<\"h5\">> = (props) => {\n const [, rest] = splitProps(props, [\"class\"])\n return <h5 class={cn(\"mb-1 font-medium leading-none tracking-tight\", props.class)} {...rest} />\n}\n\nconst AlertDescription: Component<ComponentProps<\"div\">> = (props) => {\n const [, rest] = splitProps(props, [\"class\"])\n return <div class={cn(\"text-sm [&_p]:leading-relaxed\", props.class)} {...rest} />\n}\n\nexport { Alert, AlertTitle, AlertDescription }\n"
}
],
"type": "ui"
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/public/registry/ui/avatar.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"files": [
{
"name": "avatar.tsx",
"content": "import type { Component } from \"solid-js\"\r\nimport { splitProps } from \"solid-js\"\r\n\r\nimport { Image as ImagePrimitive } from \"@kobalte/core\"\r\n\r\nimport { cn } from \"~/lib/utils\"\r\n\r\nconst Avatar: Component<ImagePrimitive.ImageRootProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return (\r\n <ImagePrimitive.Root\r\n class={cn(\"relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full\", props.class)}\r\n {...rest}\r\n />\r\n )\r\n}\r\n\r\nconst AvatarImage: Component<ImagePrimitive.ImageImgProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return <ImagePrimitive.Img class={cn(\"aspect-square h-full w-full\", props.class)} {...rest} />\r\n}\r\n\r\nconst AvatarFallback: Component<ImagePrimitive.ImageFallbackProps> = (props) => {\r\n const [, rest] = splitProps(props, [\"class\"])\r\n return (\r\n <ImagePrimitive.Fallback\r\n class={cn(\r\n \"bg-muted flex h-full w-full items-center justify-center rounded-full\",\r\n props.class\r\n )}\r\n {...rest}\r\n />\r\n )\r\n}\r\n\r\nexport { Avatar, AvatarImage, AvatarFallback }\r\n"
"content": "import type { Component } from \"solid-js\"\nimport { splitProps } from \"solid-js\"\n\nimport { Image as ImagePrimitive } from \"@kobalte/core\"\n\nimport { cn } from \"~/lib/utils\"\n\nconst Avatar: Component<ImagePrimitive.ImageRootProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\"])\n return (\n <ImagePrimitive.Root\n class={cn(\"relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full\", props.class)}\n {...rest}\n />\n )\n}\n\nconst AvatarImage: Component<ImagePrimitive.ImageImgProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\"])\n return <ImagePrimitive.Img class={cn(\"aspect-square h-full w-full\", props.class)} {...rest} />\n}\n\nconst AvatarFallback: Component<ImagePrimitive.ImageFallbackProps> = (props) => {\n const [, rest] = splitProps(props, [\"class\"])\n return (\n <ImagePrimitive.Fallback\n class={cn(\n \"bg-muted flex h-full w-full items-center justify-center rounded-full\",\n props.class\n )}\n {...rest}\n />\n )\n}\n\nexport { Avatar, AvatarImage, AvatarFallback }\n"
}
],
"type": "ui"
Expand Down
Loading

1 comment on commit 6c935ed

@vercel
Copy link

@vercel vercel bot commented on 6c935ed Dec 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.