Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
295 changes: 0 additions & 295 deletions documentation/Color system.md

This file was deleted.

5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,7 @@
"readme-update-version": "node ./scripts/readme-update-version",
"version": "yarn run readme-update-version",
"storybook": "start-storybook -p 6006 --quiet",
"storybook:build": "yarn run copy-polaris-tokens && build-storybook -o build-internal/storybook/static",
"precolordocs": "yarn run build",
"colordocs": "node ./scripts/color-system-docs",
"postcolordocs": "yarn run format"
"storybook:build": "yarn run copy-polaris-tokens && build-storybook -o build-internal/storybook/static"
},
"dependencies": {
"@shopify/polaris-icons": "^4.10.0",
Expand Down
12 changes: 0 additions & 12 deletions pre-commit
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
#!/usr/bin/ruby --disable-gems

NON_COMMITTABLE_FILE_PATHS = ['playground/Playground.tsx']
COLOR_DOC_SOURCE_FILE_PATHS = ['src/utilities/theme/tokens.ts']

module PreCommit
extend self

def main
ignore_playground
generate_color_docs
end

private
Expand All @@ -24,16 +22,6 @@ module PreCommit
end
end

def generate_color_docs
changed_files.each do |path|
if COLOR_DOC_SOURCE_FILE_PATHS.include? path
puts "Color system changes detected. Generating new docs (may take a couple minutes)..."
%x(yarn run colordocs)
%x(git add "documentation/Color system.md")
end
end
end

def changed_files
@changed_files ||= %x(git diff --cached --name-only HEAD).lines.map(&:chomp)
end
Expand Down
135 changes: 0 additions & 135 deletions scripts/color-system-docs.js

This file was deleted.

5 changes: 0 additions & 5 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,3 @@ export {
useRowSelected as useIndexTableRowSelected,
useContainerScroll as useIndexTableContainerScroll,
} from './utilities/index-table';

export {
toCssCustomPropertySyntax as UNSTABLE_toCssCustomPropertySyntax,
Tokens as UNSTABLE_Tokens,
} from './utilities/theme';
5 changes: 3 additions & 2 deletions src/utilities/custom-properties/custom-properties.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import {config} from '@shopify/polaris-tokens/dist-modern/configs/base';

import {toCssCustomPropertySyntax, Tokens} from '../theme';
function toCssCustomPropertySyntax(camelCase: string) {
return `--p-${camelCase.replace(/([A-Z]|[0-9]+)/g, '-$1').toLowerCase()}`;
}

export const nonDesignLangaugeCustomProperties = [
'--global-ribbon-height',
Expand All @@ -22,5 +24,4 @@ export const designLangaugeCustomProperties = ([] as string[]).concat(
...Object.values(config).map((variant) =>
variant.map(({name}) => toCssCustomPropertySyntax(name)),
),
...Object.keys(Tokens).map(toCssCustomPropertySyntax),
);
3 changes: 0 additions & 3 deletions src/utilities/theme/index.ts

This file was deleted.

52 changes: 0 additions & 52 deletions src/utilities/theme/tokens.ts

This file was deleted.

15 changes: 0 additions & 15 deletions src/utilities/theme/utils.ts

This file was deleted.