Skip to content

Commit

Permalink
Kurt Cobain
Browse files Browse the repository at this point in the history
  • Loading branch information
irsyadadl committed Sep 11, 2024
1 parent bdfbe7b commit 2ed4cd1
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 18 deletions.
14 changes: 9 additions & 5 deletions app/(app)/colors/(colors)/copy-json-color-shades.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,16 +35,20 @@ export function CopyJsonColorShades({
selectedFormat === "oklch"
? rgbToOklch(parseColor(color).toString("rgb"))
: parseColor(color).toString(selectedFormat as ColorFormat)
const codeString = colorScales.map(({ shade }: any) => `'${shade}': '${_selected}'`).join(",\n ")
// const codeString = colorScales.map(({ shade }: any) => `'${shade}': '${_selected}'`).join(",\n ")
const renderColorScaleAsCode = (colorScales: any, colorName: string) => {
const formattedColorName = colorName.includes("-")
? `'${getColorName(colorScales[4].color)}'`
: colorName

const codeString = colorScales
.map(
({ shade, color }: any) =>
`'${shade}': '${parseColor(color).toString(selectedFormat as ColorFormat)}'`
)
.map(({ shade, color }: any) => {
const parsedColor =
selectedFormat === "oklch"
? rgbToOklch(parseColor(color).toString("rgb"))
: parseColor(color).toString(selectedFormat as ColorFormat)
return `'${shade}': '${parsedColor}'`
})
.join(",\n ")
return `${formattedColorName}: {\n ${codeString}\n}`
}
Expand Down
Binary file modified bun.lockb
Binary file not shown.
4 changes: 2 additions & 2 deletions components/ui/drawer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ const ModalOverlayWrapper = React.forwardRef<
>((props, ref) => <ModalOverlay ref={ref} {...props} />)
ModalOverlayWrapper.displayName = "ModalOverlayWrapper"

const ModalPrimitive = motion(ModalWrapper)
const ModalOverlayPrimitive = motion(ModalOverlayWrapper)
const ModalPrimitive = motion.create(ModalWrapper)
const ModalOverlayPrimitive = motion.create(ModalOverlayWrapper)

interface DrawerOverlayPrimitiveProps
extends Omit<
Expand Down
4 changes: 2 additions & 2 deletions components/ui/multiple-select.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,9 @@ const MultipleSelect = <T extends SelectedKey>({
if (props.min !== undefined && selectedItems.items.length <= props.min) return

const key = keys.values().next().value
selectedItems.remove(key)
selectedItems.remove(key as Key)
setFieldState({ inputValue: "", selectedKey: null })
onItemCleared?.(key)
onItemCleared?.(key as Key)
updateInvalidState(selectedItems.items.length - 1)
},
[selectedItems, onItemCleared, props.min]
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"framer-motion": "^11.5.4",
"input-otp": "^1.2.4",
"justd-icons": "^1.4.45",
"next": "^14.2.8",
"next": "^14.2.9",
"next-themes": "^0.2.1",
"next-view-transitions": "^0.2.0",
"node-fetch": "^3.3.2",
Expand All @@ -40,7 +40,7 @@
"rehype-pretty-code": "^0.13.2",
"rehype-stringify": "^10.0.0",
"sharp": "^0.33.5",
"shiki": "^1.16.2",
"shiki": "^1.16.3",
"sonner": "^1.5.0",
"tailwind-merge": "^2.5.2",
"tailwind-variants": "^0.2.1",
Expand All @@ -51,7 +51,7 @@
"usemods": "^1.7.1"
},
"devDependencies": {
"@shikijs/rehype": "^1.16.2",
"@shikijs/rehype": "^1.16.3",
"@tailwindcss/typography": "^0.5.15",
"@trivago/prettier-plugin-sort-imports": "^4.3.0",
"@types/chroma-js": "^2.4.4",
Expand All @@ -64,7 +64,7 @@
"autoprefixer": "^10.4.20",
"encoding": "^0.1.13",
"eslint": "^8.57.0",
"eslint-config-next": "^14.2.8",
"eslint-config-next": "^14.2.9",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-prettier": "^5.2.1",
"husky": "^9.1.5",
Expand All @@ -74,7 +74,7 @@
"rehype-autolink-headings": "^7.1.0",
"rehype-slug": "^6.0.0",
"tailwindcss": "^3.4.10",
"typescript": "^5.5.4",
"typescript": "^5.6.2",
"velite": "0.1.0-beta.11"
},
"repository": {
Expand Down
8 changes: 4 additions & 4 deletions resources/styles/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
--success: 59.59% 0.127 163.23;
--success-fg: 97.93% 0.021 166.11;

--info: 89.72% 0.179 126.66;
--info-fg: 27.41% 0.069 132.11;
--info: 65.08% 0.1906793232945444 251.28316095209283;
--info-fg: 100% 3.5594404384177905e-8 106.37411429114086;

--muted: 96.76% 0.001 286.38;
--muted-fg: 55.19% 0.014 285.94;
Expand Down Expand Up @@ -62,8 +62,8 @@
--secondary: 27.41% 0.005 286.03;
--secondary-fg: 98.48% 0 0;

--info: 92.15% 0.209 129.31;
--info-fg: 33.18% 0.1128435250344563 142.49533888780988;
--info: 65.08% 0.1906793232945444 251.28316095209283;
--info-fg: 100% 3.5594404384177905e-8 106.37411429114086;

--success: 59.59% 0.127 163.23;
--success-fg: 97.93% 0.021 166.11;
Expand Down

0 comments on commit 2ed4cd1

Please sign in to comment.