-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Drop way too specific color definitions (#93)
- Loading branch information
Showing
83 changed files
with
4,515 additions
and
3,205 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"extends": ["prettier"], | ||
"plugins": ["prettier", "@typescript-eslint"], | ||
"rules": { | ||
"@typescript-eslint/no-unused-vars": [ | ||
"warn", | ||
{ | ||
"argsIgnorePattern": "^_", | ||
"varsIgnorePattern": "^_", | ||
"caughtErrorsIgnorePattern": "^_" | ||
} | ||
] | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
name: npm:test | ||
on: push | ||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
- uses: oven-sh/setup-bun@v1 | ||
- run: npm i | ||
- run: npm test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,37 @@ | ||
.cache | ||
.DS_Store | ||
.env | ||
.env.development.local | ||
.env.local | ||
.env.test | ||
.eslintcache | ||
.git | ||
.next | ||
.node_repl_history | ||
.nova | ||
.now | ||
.npm | ||
.sentryclirc | ||
.tmp | ||
.turbo | ||
.vercel | ||
.vscode | ||
out | ||
.yarn | ||
.yarn-integrity | ||
*.lcov | ||
*.log | ||
*.pid | ||
*.pid.lock | ||
*.seed | ||
*.tsbuildinfo | ||
# next-env.d.ts | ||
coverage | ||
dist | ||
dist-demo | ||
node_modules | ||
yarn-error.log | ||
logs | ||
node_modules/ | ||
npm-debug.log* | ||
pids | ||
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json | ||
typings/ | ||
yarn-debug.log* | ||
yarn-error.log* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
.git | ||
.env | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
{ | ||
"tabWidth": 2, | ||
"semi": false, | ||
"tabWidth": 4, | ||
"useTabs": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,34 @@ | ||
{ | ||
"author": "Chris Puska <03b8@helios.graphics>", | ||
"author": "03b8 <03b8@helios.graphics>", | ||
"private": false, | ||
"license": "MIT", | ||
"version": "4.0.0-alpha-5", | ||
"version": "5.0.0", | ||
"scripts": { | ||
"test": "vitest", | ||
"test": "NODE_ENV=test vitest run", | ||
"test:u": "NODE_ENV=test vitest run --update", | ||
"test:watch": "NODE_ENV=test vitest", | ||
"test:coverage": "NODE_ENV=test vitest run --coverage", | ||
"pub:fractures": "pnpm publish --access public --filter fractures", | ||
"pub:library": "pnpm publish --access public --filter library", | ||
"pub:utils": "pnpm publish --access public --filter utils", | ||
"fractures:build": "pnpm run --filter fractures build" | ||
"prettier:write": "prettier --no-semi --use-tabs --write ./packages/**" | ||
}, | ||
"workspaces": [ | ||
"packages/*" | ||
], | ||
"dependencies": {}, | ||
"devDependencies": { | ||
"@types/node": "^20.6.3", | ||
"@types/react": "^18.2.22", | ||
"eslint": "^8.50.0", | ||
"eslint-config-next": "^13.5.2", | ||
"prettier": "^3.0.3", | ||
"typescript": "^5.2.2", | ||
"vitest": "^1.1.0" | ||
"@typescript-eslint/eslint-plugin": "latest", | ||
"@types/node": "latest", | ||
"@types/react": "latest", | ||
"@vitest/coverage-v8": "latest", | ||
"eslint": "latest", | ||
"eslint-config-prettier": "latest", | ||
"eslint-plugin-prettier": "latest", | ||
"jsdom": "latest", | ||
"prettier": "latest", | ||
"typescript": "latest", | ||
"vite": "latest", | ||
"vitest": "latest" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,51 @@ | ||
import { fractureFiles } from "library/src/index"; | ||
import { generateOutput } from "./generators"; | ||
import { reset } from "./root.reset"; | ||
import { easings } from "./root.easings"; | ||
import { config } from "./root.config"; | ||
import { writeFile } from "./utils"; | ||
import { borderRadius } from "./rules/border-radius" | ||
import { config } from "./root.config" | ||
import { cursor } from "./rules/cursor" | ||
import { display } from "./rules/display" | ||
import { easings } from "./root.easings" | ||
import { flex } from "./rules/flex" | ||
import { generateOutput } from "./generators" | ||
import { grid } from "./rules/grid" | ||
import { height } from "./rules/height" | ||
import { list } from "./rules/list" | ||
import { margin } from "./rules/margin" | ||
import { opacity } from "./rules/opacity" | ||
import { overflow } from "./rules/overflow" | ||
import { padding } from "./rules/padding" | ||
import { position } from "./rules/position" | ||
import { reset } from "./root.reset" | ||
import { type } from "./rules/type" | ||
import { width } from "./rules/width" | ||
import { writeFile } from "./utils" | ||
import type { FractureFiles } from "./types/meta" | ||
|
||
// Generate standalone config CSS | ||
writeFile('dist/fractures.reset.css', reset); | ||
writeFile('dist/fractures.config.css', config); | ||
writeFile('dist/fractures.easings.css', easings); | ||
export const fractureFiles: FractureFiles = { | ||
borderRadius, | ||
cursor, | ||
display, | ||
flex, | ||
grid, | ||
height, | ||
list, | ||
margin, | ||
opacity, | ||
overflow, | ||
padding, | ||
position, | ||
type, | ||
width, | ||
} | ||
|
||
// Generate default bundle | ||
generateOutput(fractureFiles, config + reset, "dist/fractures.min.css"); | ||
// generates standalone versions, each containing only their specific parts. | ||
// TODO this can be just a copy. | ||
writeFile("dist/fractures.reset.css", reset) | ||
writeFile("dist/fractures.config.css", config) | ||
writeFile("dist/fractures.easings.css", easings) | ||
|
||
// Generate file sets | ||
Object.entries(fractureFiles).forEach(rules => { | ||
generateOutput(rules[1], '', `dist/set/${rules[0]}.css`); | ||
// generates the default bundle. | ||
generateOutput(fractureFiles, config + reset, "dist/fractures.min.css") | ||
|
||
// generates set of files, eg.: `@heliosgraphics/fractures/dist/set/flex.css` | ||
Object.entries(fractureFiles).forEach((rules) => { | ||
generateOutput(rules[1], "", `dist/set/${rules[0]}.css`) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.