From cc1f604a0c70439582068b3a431bbf986e035245 Mon Sep 17 00:00:00 2001 From: Marc G Date: Tue, 18 Jun 2024 00:35:39 +0200 Subject: [PATCH 1/2] add missing properties --- .eslintrc.js | 1 + data/all.json | 44 +++++++++++++++++++++++++++++++++ scripts/generate.mjs | 7 +++--- source/browsers/safari-1.1.json | 13 ++++++++++ source/browsers/safari-2.0.json | 28 +++++++++++++++++++++ source/unknown.json | 23 +++++++++++++++++ 6 files changed, 113 insertions(+), 3 deletions(-) create mode 100644 source/browsers/safari-1.1.json create mode 100644 source/browsers/safari-2.0.json create mode 100644 source/unknown.json diff --git a/.eslintrc.js b/.eslintrc.js index 79450c0..5ccd918 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,4 +1,5 @@ module.exports = { + sourceType: 'module', extends: 'eslint:recommended', env: { node: true, diff --git a/data/all.json b/data/all.json index fac82d0..fcaece9 100644 --- a/data/all.json +++ b/data/all.json @@ -72,6 +72,7 @@ "app-region", "-webkit-app-region", "appearance", + "-khtml-appearance", "-moz-appearance", "-webkit-appearance", "ascent-override", @@ -119,6 +120,7 @@ "baseline-shift", "baseline-source", "behavior", + "-khtml-binding", "-moz-binding", "block-ellipsis", "-ms-block-progression", @@ -175,6 +177,7 @@ "-moz-border-end-width", "-webkit-border-end-width", "-webkit-border-fit", + "-khtml-border-horizontal-spacing", "-webkit-border-horizontal-spacing", "border-image", "-moz-border-image", @@ -240,23 +243,33 @@ "-webkit-border-top-right-radius", "border-top-style", "border-top-width", + "-khtml-border-vertical-spacing", "-webkit-border-vertical-spacing", "border-width", "bottom", + "-khtml-box-align", "-moz-box-align", "-webkit-box-align", "box-decoration-break", "-webkit-box-decoration-break", + "-khtml-box-direction", "-moz-box-direction", "-webkit-box-direction", + "-khtml-box-flex-group", + "-khtml-box-flex-group-transition", "-webkit-box-flex-group", + "-khtml-box-flex", "-moz-box-flex", "-webkit-box-flex", + "-khtml-box-lines", "-webkit-box-lines", + "-khtml-box-ordinal-group", "-moz-box-ordinal-group", "-webkit-box-ordinal-group", + "-khtml-box-orient", "-moz-box-orient", "-webkit-box-orient", + "-khtml-box-pack", "-moz-box-pack", "-webkit-box-pack", "-webkit-box-reflect", @@ -361,6 +374,7 @@ "cy", "d", "-apple-dashboard-region", + "-khtml-dashboard-region", "-webkit-dashboard-region", "descent-override", "direction", @@ -440,6 +454,8 @@ "flow-into", "-ms-flow-into", "-webkit-flow-into", + "-khtml-flow-mode", + "-konq-flow-mode", "font", "font-display", "font-family", @@ -455,6 +471,7 @@ "font-palette", "font-size", "font-size-adjust", + "-khtml-font-size-delta", "-webkit-font-size-delta", "-webkit-font-smoothing", "font-stretch", @@ -524,6 +541,7 @@ "height", "-ms-high-contrast-adjust", "-webkit-highlight", + "-khtml-horizontal-border-spacing", "hyphenate-character", "-webkit-hyphenate-character", "-webkit-hyphenate-limit-after", @@ -568,6 +586,7 @@ "inset-inline-start", "-ms-interpolation-mode", "isolation", + "-konq-js-clip", "justify-content", "-webkit-justify-content", "justify-items", @@ -587,8 +606,11 @@ "-webkit-line-align", "-webkit-line-box-contain", "line-break", + "-khtml-line-break", "-webkit-line-break", "line-clamp", + "-apple-line-clamp", + "-khtml-line-clamp", "-webkit-line-clamp", "line-gap-override", "line-grid", @@ -618,8 +640,10 @@ "margin-block-end", "margin-block-start", "margin-bottom", + "-khtml-margin-bottom-collapse", "-webkit-margin-bottom-collapse", "margin-break", + "-khtml-margin-collapse", "-webkit-margin-collapse", "-moz-margin-end", "-webkit-margin-end", @@ -628,9 +652,11 @@ "margin-inline-start", "margin-left", "margin-right", + "-khtml-margin-start", "-moz-margin-start", "-webkit-margin-start", "margin-top", + "-khtml-margin-top-collapse", "-webkit-margin-top-collapse", "margin-trim", "marker", @@ -645,12 +671,18 @@ "marker-start", "marks", "-wap-marquee-dir", + "-khtml-marquee-direction", "-webkit-marquee-direction", + "-khtml-marquee-increment", "-webkit-marquee-increment", + "-khtml-marquee", "-wap-marquee-loop", + "-khtml-marquee-repetition", "-webkit-marquee-repetition", + "-khtml-marquee-speed", "-wap-marquee-speed", "-webkit-marquee-speed", + "-khtml-marquee-style", "-wap-marquee-style", "-webkit-marquee-style", "-webkit-marquee", @@ -694,6 +726,7 @@ "-webkit-mask-source-type", "mask-type", "-webkit-mask", + "-khtml-match-nearest-mail-blockquote-color", "-webkit-match-nearest-mail-blockquote-color", "math-depth", "math-shift", @@ -725,6 +758,7 @@ "nav-right", "nav-up", "navigation", + "-khtml-nbsp-mode", "-webkit-nbsp-mode", "negative", "object-fit", @@ -744,6 +778,7 @@ "offset-rotate", "offset-rotation", "opacity", + "-khtml-opacity", "-moz-opacity", "-webkit-opacity", "order", @@ -809,6 +844,7 @@ "padding-inline-start", "padding-left", "padding-right", + "-khtml-padding-start", "-moz-padding-start", "-webkit-padding-start", "padding-top", @@ -870,6 +906,7 @@ "right", "rotate", "row-gap", + "-khtml-rtl-ordering", "-webkit-rtl-ordering", "ruby-align", "ruby-merge", @@ -1051,6 +1088,7 @@ "text-decoration-trim", "text-decoration-underline", "-webkit-text-decoration", + "-khtml-text-decorations-in-effect", "-webkit-text-decorations-in-effect", "text-emphasis", "text-emphasis-color", @@ -1085,6 +1123,8 @@ "-webkit-text-security", "text-shadow", "text-size-adjust", + "-apple-text-size-adjust", + "-khtml-text-size-adjust", "-moz-text-size-adjust", "-ms-text-size-adjust", "-webkit-text-size-adjust", @@ -1167,18 +1207,22 @@ "uc-skin", "unicode-bidi", "unicode-range", + "-khtml-user-drag", "-webkit-user-drag", "-moz-user-focus", "-moz-user-input", + "-khtml-user-modify", "-moz-user-modify", "-webkit-user-modify", "user-select", + "-khtml-user-select", "-moz-user-select", "-ms-user-select", "-webkit-user-select", "user-zoom", "vector-effect", "vertical-align", + "-khtml-vertical-border-spacing", "view-timeline", "view-timeline-axis", "view-timeline-inset", diff --git a/scripts/generate.mjs b/scripts/generate.mjs index af99122..b503ffa 100644 --- a/scripts/generate.mjs +++ b/scripts/generate.mjs @@ -5,11 +5,12 @@ import fs from 'fs/promises'; import path from 'path'; import { globby } from 'globby'; import uniq from 'lodash.uniq'; -import sortBy from 'lodash.sortBy'; +import sortBy from 'lodash.sortby'; const W3C_SOURCE_FILEPATH = path.join(process.cwd(), 'source/w3c.json'); +const UNKNOWN_FILEPATH = path.join(process.cwd(), 'source/unknown.json'); const BROWSERS_SOURCE_DIR = path.join(process.cwd(), 'source/browsers'); -const SORT_PATTERN = new RegExp('^-(webkit|moz|ms|o|apple|wap)-(.*)') +const SORT_PATTERN = new RegExp('^-(khtml|konq|webkit|moz|ms|o|apple|wap)-(.*)') const OUTPUT = path.join(process.cwd(), 'data/all.json'); async function readJSON(filepath) { @@ -23,7 +24,7 @@ async function saveJSON(properties) { (async () => { const browserSourceFilepaths = await globby('*.json', { cwd: BROWSERS_SOURCE_DIR, absolute: true }); - const sourceFilepaths = [W3C_SOURCE_FILEPATH, ...browserSourceFilepaths]; + const sourceFilepaths = [W3C_SOURCE_FILEPATH, UNKNOWN_FILEPATH, ...browserSourceFilepaths]; const data = await Promise.all(sourceFilepaths.map(readJSON)); const allProperties = data.map(({ properties }) => properties).flat(); diff --git a/source/browsers/safari-1.1.json b/source/browsers/safari-1.1.json new file mode 100644 index 0000000..388fe9b --- /dev/null +++ b/source/browsers/safari-1.1.json @@ -0,0 +1,13 @@ +{ + "properties": [ + "-khtml-opacity", + "-khtml-box-align", + "-khtml-box-direction", + "-khtml-box-flex", + "-khtml-box-flex-group", + "-khtml-box-lines", + "-khtml-box-ordinal-group", + "-khtml-box-orient", + "-khtml-box-pack" + ] +} \ No newline at end of file diff --git a/source/browsers/safari-2.0.json b/source/browsers/safari-2.0.json new file mode 100644 index 0000000..edaac40 --- /dev/null +++ b/source/browsers/safari-2.0.json @@ -0,0 +1,28 @@ +{ + "properties": [ + "-khtml-border-horizontal-spacing", + "-khtml-border-vertical-spacing", + "-khtml-box-align", + "-khtml-box-direction", + "-khtml-box-flex", + "-khtml-box-flex-group", + "-khtml-box-lines", + "-khtml-box-ordinal-group", + "-khtml-box-orient", + "-khtml-box-pack", + "-khtml-line-break", + "-khtml-margin-bottom-collapse", + "-khtml-margin-start", + "-khtml-marquee", + "-khtml-marquee-direction", + "-khtml-marquee-increment", + "-khtml-marquee-repetition", + "-khtml-marquee-speed", + "-khtml-marquee-style", + "-khtml-nbsp-mode", + "-khtml-padding-start", + "-khtml-user-drag", + "-khtml-user-modify", + "-khtml-user-select" + ] +} \ No newline at end of file diff --git a/source/unknown.json b/source/unknown.json new file mode 100644 index 0000000..a2a9c9e --- /dev/null +++ b/source/unknown.json @@ -0,0 +1,23 @@ +{ + "properties": [ + "-apple-line-clamp", + "-apple-text-size-adjust", + "-khtml-appearance", + "-khtml-binding", + "-khtml-box-flex-group-transition", + "-khtml-dashboard-region", + "-khtml-flow-mode", + "-khtml-font-size-delta", + "-khtml-horizontal-border-spacing", + "-khtml-line-clamp", + "-khtml-margin-collapse", + "-khtml-margin-top-collapse", + "-khtml-match-nearest-mail-blockquote-color", + "-khtml-rtl-ordering", + "-khtml-text-decorations-in-effect", + "-khtml-text-size-adjust", + "-khtml-vertical-border-spacing", + "-konq-flow-mode", + "-konq-js-clip" + ] +} \ No newline at end of file From 7a5c39e7adc2339bf4040ca78db8dd2f45049679 Mon Sep 17 00:00:00 2001 From: Marc G Date: Tue, 18 Jun 2024 00:39:18 +0200 Subject: [PATCH 2/2] update README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 62064db..8447d6c 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ List of standard and browser specific CSS properties. | Chrome | 14 - 126 | | Firefox | 6 - 127 | | Edge | 13 - 18 | -| Safari | 6, 6.2, 7 - 9, 9.1, 10.0, 11.0, 11.1, 12.0, 12.1, 13.0, 13.1, 14, 14.1, 15.1, 15.4, 16.0, 16.5, 17.0, 17.1, 17.3 | +| Safari | 1.1, 2, 6, 6.2, 7 - 9, 9.1, 10.0, 11.0, 11.1, 12.0, 12.1, 13.0, 13.1, 14, 14.1, 15.1, 15.4, 16.0, 16.5, 17.0, 17.1, 17.3 | | Internet Explorer | 8 - 11 | | Opera | 12.10, 12.14, 12.15, 12.16, 36 - 40, 45, 56, 58 |