@pierre/theme 0.0.23 → 0.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/publish.yml +6 -0
- package/.github/workflows/test.yml +14 -0
- package/.vscodeignore +1 -0
- package/README.md +26 -2
- package/package.json +12 -2
- package/src/build.ts +21 -0
- package/src/palette.ts +2 -2
- package/themes/pierre-dark-vibrant.json +5 -5
- package/themes/pierre-dark.json +5 -5
- package/themes/pierre-light-vibrant.json +5 -5
- package/themes/pierre-light.json +5 -5
- package/zed/extension.toml +1 -1
- package/color-comparison.html +0 -234
|
@@ -44,6 +44,20 @@ jobs:
|
|
|
44
44
|
fi
|
|
45
45
|
echo "✅ All theme files generated successfully"
|
|
46
46
|
|
|
47
|
+
- name: Verify ESM wrapper modules exist
|
|
48
|
+
run: |
|
|
49
|
+
for theme in pierre-dark pierre-light pierre-dark-vibrant pierre-light-vibrant; do
|
|
50
|
+
if [ ! -f "dist/${theme}.mjs" ]; then
|
|
51
|
+
echo "❌ dist/${theme}.mjs not generated"
|
|
52
|
+
exit 1
|
|
53
|
+
fi
|
|
54
|
+
done
|
|
55
|
+
if [ ! -f "dist/index.mjs" ]; then
|
|
56
|
+
echo "❌ dist/index.mjs not generated"
|
|
57
|
+
exit 1
|
|
58
|
+
fi
|
|
59
|
+
echo "✅ All ESM wrapper modules generated successfully"
|
|
60
|
+
|
|
47
61
|
- name: Check file sizes
|
|
48
62
|
run: |
|
|
49
63
|
light_size=$(wc -c < themes/pierre-light.json)
|
package/.vscodeignore
CHANGED
package/README.md
CHANGED
|
@@ -11,6 +11,30 @@ OPEN POSITIONS: [Systems Engineer](https://pierre.computer/careers/systems-engin
|
|
|
11
11
|
|
|
12
12
|
~~~
|
|
13
13
|
|
|
14
|
-
Overview:
|
|
15
|
-
- Light and dark themes for Visual Studio Code, Cursor, Zed, and Shiki.
|
|
14
|
+
Overview:
|
|
15
|
+
- Light and dark themes for Visual Studio Code, Cursor, Zed, and Shiki.
|
|
16
16
|
- Built for [Diffs.com](https://diffs.com)
|
|
17
|
+
|
|
18
|
+
~~~
|
|
19
|
+
|
|
20
|
+
Usage:
|
|
21
|
+
|
|
22
|
+
VS Code / Cursor:
|
|
23
|
+
1. Install "Pierre Theme" from the Extensions marketplace
|
|
24
|
+
2. Cmd+Shift+P > "Color Theme" > select Pierre Light or Pierre Dark
|
|
25
|
+
|
|
26
|
+
Shiki / npm:
|
|
27
|
+
npm install @pierre/theme
|
|
28
|
+
|
|
29
|
+
import pierreDark from '@pierre/theme/pierre-dark'
|
|
30
|
+
import pierreLight from '@pierre/theme/pierre-light'
|
|
31
|
+
|
|
32
|
+
Available themes:
|
|
33
|
+
- @pierre/theme/pierre-dark
|
|
34
|
+
- @pierre/theme/pierre-light
|
|
35
|
+
- @pierre/theme/pierre-dark-vibrant (Display P3)
|
|
36
|
+
- @pierre/theme/pierre-light-vibrant (Display P3)
|
|
37
|
+
|
|
38
|
+
Zed:
|
|
39
|
+
Install "Pierre" from the Zed extension registry
|
|
40
|
+
```
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@pierre/theme",
|
|
3
3
|
"displayName": "Pierre Theme",
|
|
4
4
|
"description": "Pierre theme for Shiki, VS Code, and more",
|
|
5
|
-
"version": "0.0.
|
|
5
|
+
"version": "0.0.25",
|
|
6
6
|
"publisher": "pierrecomputer",
|
|
7
7
|
"icon": "icon.png",
|
|
8
8
|
"galleryBanner": {
|
|
@@ -47,7 +47,8 @@
|
|
|
47
47
|
"build": "ts-node src/build.ts",
|
|
48
48
|
"test": "npm run build && ts-node src/test.ts",
|
|
49
49
|
"start": "nodemon --watch src --ext ts --exec npm run build",
|
|
50
|
-
"package": "ts-node src/package-vsix.ts"
|
|
50
|
+
"package": "ts-node src/package-vsix.ts",
|
|
51
|
+
"prepublishOnly": "npm run build"
|
|
51
52
|
},
|
|
52
53
|
"devDependencies": {
|
|
53
54
|
"@vscode/vsce": "^3.2.2",
|
|
@@ -55,6 +56,15 @@
|
|
|
55
56
|
"ts-node": "^10.9.2",
|
|
56
57
|
"typescript": "^5.9.3"
|
|
57
58
|
},
|
|
59
|
+
"sideEffects": false,
|
|
60
|
+
"exports": {
|
|
61
|
+
".": "./dist/index.mjs",
|
|
62
|
+
"./pierre-dark": "./dist/pierre-dark.mjs",
|
|
63
|
+
"./pierre-light": "./dist/pierre-light.mjs",
|
|
64
|
+
"./pierre-dark-vibrant": "./dist/pierre-dark-vibrant.mjs",
|
|
65
|
+
"./pierre-light-vibrant": "./dist/pierre-light-vibrant.mjs",
|
|
66
|
+
"./themes/*": "./themes/*"
|
|
67
|
+
},
|
|
58
68
|
"publishConfig": {
|
|
59
69
|
"access": "public"
|
|
60
70
|
}
|
package/src/build.ts
CHANGED
|
@@ -37,3 +37,24 @@ const zedTheme = makeZedThemeFamily("Pierre", "pierrecomputer", [
|
|
|
37
37
|
|
|
38
38
|
writeFileSync("zed/themes/pierre.json", JSON.stringify(zedTheme, null, 2), "utf8");
|
|
39
39
|
console.log("Wrote zed/themes/pierre.json");
|
|
40
|
+
|
|
41
|
+
// ============================================
|
|
42
|
+
// ESM wrapper modules (for npm / Shiki consumers)
|
|
43
|
+
// ============================================
|
|
44
|
+
mkdirSync("dist", { recursive: true });
|
|
45
|
+
|
|
46
|
+
const themeNames: string[] = [];
|
|
47
|
+
|
|
48
|
+
for (const { file, theme } of vscodeThemes) {
|
|
49
|
+
const name = file.replace("themes/", "").replace(".json", "");
|
|
50
|
+
themeNames.push(name);
|
|
51
|
+
const json = JSON.stringify(theme);
|
|
52
|
+
const escaped = json.replace(/\\/g, "\\\\").replace(/'/g, "\\'");
|
|
53
|
+
const mjs = `export default Object.freeze(JSON.parse('${escaped}'))\n`;
|
|
54
|
+
writeFileSync(`dist/${name}.mjs`, mjs, "utf8");
|
|
55
|
+
console.log("Wrote", `dist/${name}.mjs`);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
const indexMjs = `export const themeNames = ${JSON.stringify(themeNames)}\n`;
|
|
59
|
+
writeFileSync("dist/index.mjs", indexMjs, "utf8");
|
|
60
|
+
console.log("Wrote dist/index.mjs");
|
package/src/palette.ts
CHANGED
|
@@ -277,7 +277,7 @@ export const light: Roles = {
|
|
|
277
277
|
namespace: yellow["600"],
|
|
278
278
|
decorator: blue["500"],
|
|
279
279
|
escape: cyan["600"],
|
|
280
|
-
invalid: "
|
|
280
|
+
invalid: gray["1040"],
|
|
281
281
|
tag: red["600"],
|
|
282
282
|
attribute: mint["600"]
|
|
283
283
|
},
|
|
@@ -354,7 +354,7 @@ export const dark: Roles = {
|
|
|
354
354
|
namespace: yellow["500"],
|
|
355
355
|
decorator: blue["400"],
|
|
356
356
|
escape: cyan["400"],
|
|
357
|
-
invalid: "
|
|
357
|
+
invalid: gray["020"],
|
|
358
358
|
tag: red["400"],
|
|
359
359
|
attribute: mint["400"]
|
|
360
360
|
},
|
|
@@ -1405,7 +1405,7 @@
|
|
|
1405
1405
|
{
|
|
1406
1406
|
"scope": "constant.other.color.rgb-value.xi",
|
|
1407
1407
|
"settings": {
|
|
1408
|
-
"foreground": "color(display-p3
|
|
1408
|
+
"foreground": "color(display-p3 0.984314 0.984314 0.984314)"
|
|
1409
1409
|
}
|
|
1410
1410
|
},
|
|
1411
1411
|
{
|
|
@@ -1874,25 +1874,25 @@
|
|
|
1874
1874
|
{
|
|
1875
1875
|
"scope": "invalid.illegal",
|
|
1876
1876
|
"settings": {
|
|
1877
|
-
"foreground": "color(display-p3
|
|
1877
|
+
"foreground": "color(display-p3 0.984314 0.984314 0.984314)"
|
|
1878
1878
|
}
|
|
1879
1879
|
},
|
|
1880
1880
|
{
|
|
1881
1881
|
"scope": "invalid.broken",
|
|
1882
1882
|
"settings": {
|
|
1883
|
-
"foreground": "color(display-p3
|
|
1883
|
+
"foreground": "color(display-p3 0.984314 0.984314 0.984314)"
|
|
1884
1884
|
}
|
|
1885
1885
|
},
|
|
1886
1886
|
{
|
|
1887
1887
|
"scope": "invalid.deprecated",
|
|
1888
1888
|
"settings": {
|
|
1889
|
-
"foreground": "color(display-p3
|
|
1889
|
+
"foreground": "color(display-p3 0.984314 0.984314 0.984314)"
|
|
1890
1890
|
}
|
|
1891
1891
|
},
|
|
1892
1892
|
{
|
|
1893
1893
|
"scope": "invalid.unimplemented",
|
|
1894
1894
|
"settings": {
|
|
1895
|
-
"foreground": "color(display-p3
|
|
1895
|
+
"foreground": "color(display-p3 0.984314 0.984314 0.984314)"
|
|
1896
1896
|
}
|
|
1897
1897
|
}
|
|
1898
1898
|
],
|
package/themes/pierre-dark.json
CHANGED
|
@@ -1405,7 +1405,7 @@
|
|
|
1405
1405
|
{
|
|
1406
1406
|
"scope": "constant.other.color.rgb-value.xi",
|
|
1407
1407
|
"settings": {
|
|
1408
|
-
"foreground": "#
|
|
1408
|
+
"foreground": "#fbfbfb"
|
|
1409
1409
|
}
|
|
1410
1410
|
},
|
|
1411
1411
|
{
|
|
@@ -1874,25 +1874,25 @@
|
|
|
1874
1874
|
{
|
|
1875
1875
|
"scope": "invalid.illegal",
|
|
1876
1876
|
"settings": {
|
|
1877
|
-
"foreground": "#
|
|
1877
|
+
"foreground": "#fbfbfb"
|
|
1878
1878
|
}
|
|
1879
1879
|
},
|
|
1880
1880
|
{
|
|
1881
1881
|
"scope": "invalid.broken",
|
|
1882
1882
|
"settings": {
|
|
1883
|
-
"foreground": "#
|
|
1883
|
+
"foreground": "#fbfbfb"
|
|
1884
1884
|
}
|
|
1885
1885
|
},
|
|
1886
1886
|
{
|
|
1887
1887
|
"scope": "invalid.deprecated",
|
|
1888
1888
|
"settings": {
|
|
1889
|
-
"foreground": "#
|
|
1889
|
+
"foreground": "#fbfbfb"
|
|
1890
1890
|
}
|
|
1891
1891
|
},
|
|
1892
1892
|
{
|
|
1893
1893
|
"scope": "invalid.unimplemented",
|
|
1894
1894
|
"settings": {
|
|
1895
|
-
"foreground": "#
|
|
1895
|
+
"foreground": "#fbfbfb"
|
|
1896
1896
|
}
|
|
1897
1897
|
}
|
|
1898
1898
|
],
|
|
@@ -1405,7 +1405,7 @@
|
|
|
1405
1405
|
{
|
|
1406
1406
|
"scope": "constant.other.color.rgb-value.xi",
|
|
1407
1407
|
"settings": {
|
|
1408
|
-
"foreground": "color(display-p3
|
|
1408
|
+
"foreground": "color(display-p3 0.027451 0.027451 0.027451)"
|
|
1409
1409
|
}
|
|
1410
1410
|
},
|
|
1411
1411
|
{
|
|
@@ -1874,25 +1874,25 @@
|
|
|
1874
1874
|
{
|
|
1875
1875
|
"scope": "invalid.illegal",
|
|
1876
1876
|
"settings": {
|
|
1877
|
-
"foreground": "color(display-p3
|
|
1877
|
+
"foreground": "color(display-p3 0.027451 0.027451 0.027451)"
|
|
1878
1878
|
}
|
|
1879
1879
|
},
|
|
1880
1880
|
{
|
|
1881
1881
|
"scope": "invalid.broken",
|
|
1882
1882
|
"settings": {
|
|
1883
|
-
"foreground": "color(display-p3
|
|
1883
|
+
"foreground": "color(display-p3 0.027451 0.027451 0.027451)"
|
|
1884
1884
|
}
|
|
1885
1885
|
},
|
|
1886
1886
|
{
|
|
1887
1887
|
"scope": "invalid.deprecated",
|
|
1888
1888
|
"settings": {
|
|
1889
|
-
"foreground": "color(display-p3
|
|
1889
|
+
"foreground": "color(display-p3 0.027451 0.027451 0.027451)"
|
|
1890
1890
|
}
|
|
1891
1891
|
},
|
|
1892
1892
|
{
|
|
1893
1893
|
"scope": "invalid.unimplemented",
|
|
1894
1894
|
"settings": {
|
|
1895
|
-
"foreground": "color(display-p3
|
|
1895
|
+
"foreground": "color(display-p3 0.027451 0.027451 0.027451)"
|
|
1896
1896
|
}
|
|
1897
1897
|
}
|
|
1898
1898
|
],
|
package/themes/pierre-light.json
CHANGED
|
@@ -1405,7 +1405,7 @@
|
|
|
1405
1405
|
{
|
|
1406
1406
|
"scope": "constant.other.color.rgb-value.xi",
|
|
1407
1407
|
"settings": {
|
|
1408
|
-
"foreground": "#
|
|
1408
|
+
"foreground": "#070707"
|
|
1409
1409
|
}
|
|
1410
1410
|
},
|
|
1411
1411
|
{
|
|
@@ -1874,25 +1874,25 @@
|
|
|
1874
1874
|
{
|
|
1875
1875
|
"scope": "invalid.illegal",
|
|
1876
1876
|
"settings": {
|
|
1877
|
-
"foreground": "#
|
|
1877
|
+
"foreground": "#070707"
|
|
1878
1878
|
}
|
|
1879
1879
|
},
|
|
1880
1880
|
{
|
|
1881
1881
|
"scope": "invalid.broken",
|
|
1882
1882
|
"settings": {
|
|
1883
|
-
"foreground": "#
|
|
1883
|
+
"foreground": "#070707"
|
|
1884
1884
|
}
|
|
1885
1885
|
},
|
|
1886
1886
|
{
|
|
1887
1887
|
"scope": "invalid.deprecated",
|
|
1888
1888
|
"settings": {
|
|
1889
|
-
"foreground": "#
|
|
1889
|
+
"foreground": "#070707"
|
|
1890
1890
|
}
|
|
1891
1891
|
},
|
|
1892
1892
|
{
|
|
1893
1893
|
"scope": "invalid.unimplemented",
|
|
1894
1894
|
"settings": {
|
|
1895
|
-
"foreground": "#
|
|
1895
|
+
"foreground": "#070707"
|
|
1896
1896
|
}
|
|
1897
1897
|
}
|
|
1898
1898
|
],
|
package/zed/extension.toml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
id = "pierre-theme"
|
|
2
2
|
name = "Pierre"
|
|
3
3
|
description = "A warm, orange-accented color theme with light and dark variants"
|
|
4
|
-
version = "0.0.
|
|
4
|
+
version = "0.0.25"
|
|
5
5
|
schema_version = 1
|
|
6
6
|
authors = ["pierrecomputer"]
|
|
7
7
|
repository = "https://github.com/pierrecomputer/pierre-theme"
|
package/color-comparison.html
DELETED
|
@@ -1,234 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="UTF-8">
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
|
-
<title>Pierre Theme - Display P3 Color Comparison</title>
|
|
7
|
-
<style>
|
|
8
|
-
body {
|
|
9
|
-
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
|
|
10
|
-
max-width: 1200px;
|
|
11
|
-
margin: 40px auto;
|
|
12
|
-
padding: 20px;
|
|
13
|
-
background: #141415;
|
|
14
|
-
color: #fbfbfb;
|
|
15
|
-
}
|
|
16
|
-
h1 { text-align: center; margin-bottom: 40px; }
|
|
17
|
-
.comparison-grid {
|
|
18
|
-
display: grid;
|
|
19
|
-
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
|
|
20
|
-
gap: 30px;
|
|
21
|
-
margin: 40px 0;
|
|
22
|
-
}
|
|
23
|
-
.color-card {
|
|
24
|
-
background: #1f1f21;
|
|
25
|
-
border-radius: 12px;
|
|
26
|
-
padding: 20px;
|
|
27
|
-
border: 1px solid #39393c;
|
|
28
|
-
}
|
|
29
|
-
.color-card h3 {
|
|
30
|
-
margin-top: 0;
|
|
31
|
-
color: #fbfbfb;
|
|
32
|
-
}
|
|
33
|
-
.color-swatch {
|
|
34
|
-
height: 100px;
|
|
35
|
-
border-radius: 8px;
|
|
36
|
-
margin: 10px 0;
|
|
37
|
-
display: flex;
|
|
38
|
-
align-items: center;
|
|
39
|
-
justify-content: center;
|
|
40
|
-
font-weight: 600;
|
|
41
|
-
font-family: 'Monaco', 'Courier New', monospace;
|
|
42
|
-
font-size: 12px;
|
|
43
|
-
color: white;
|
|
44
|
-
text-shadow: 0 0 2px rgba(0,0,0,0.5);
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
.label {
|
|
48
|
-
font-size: 12px;
|
|
49
|
-
color: #adadb1;
|
|
50
|
-
margin-bottom: 5px;
|
|
51
|
-
margin-top: 15px;
|
|
52
|
-
}
|
|
53
|
-
.hex-value {
|
|
54
|
-
font-family: 'Monaco', 'Courier New', monospace;
|
|
55
|
-
font-size: 11px;
|
|
56
|
-
color: #c6c6c8;
|
|
57
|
-
margin-top: 5px;
|
|
58
|
-
word-break: break-all;
|
|
59
|
-
}
|
|
60
|
-
.info {
|
|
61
|
-
background: #2e2e30;
|
|
62
|
-
padding: 20px;
|
|
63
|
-
border-radius: 8px;
|
|
64
|
-
margin: 20px 0;
|
|
65
|
-
border-left: 4px solid color(display-p3 0.340 0.734 0.360);
|
|
66
|
-
}
|
|
67
|
-
.info h3 {
|
|
68
|
-
margin-top: 0;
|
|
69
|
-
}
|
|
70
|
-
.p3-notice {
|
|
71
|
-
text-align: center;
|
|
72
|
-
padding: 15px;
|
|
73
|
-
background: #39393c;
|
|
74
|
-
border-radius: 8px;
|
|
75
|
-
margin: 20px 0;
|
|
76
|
-
}
|
|
77
|
-
.supports { color: color(display-p3 0.340 0.734 0.360); }
|
|
78
|
-
.no-support { color: #ff6762; }
|
|
79
|
-
|
|
80
|
-
code {
|
|
81
|
-
background: #2e2e30;
|
|
82
|
-
padding: 2px 6px;
|
|
83
|
-
border-radius: 4px;
|
|
84
|
-
font-size: 13px;
|
|
85
|
-
}
|
|
86
|
-
</style>
|
|
87
|
-
</head>
|
|
88
|
-
<body>
|
|
89
|
-
<h1>Pierre Theme: Display P3 Color Comparison</h1>
|
|
90
|
-
|
|
91
|
-
<div class="p3-notice" id="p3-status">
|
|
92
|
-
Checking Display P3 support...
|
|
93
|
-
</div>
|
|
94
|
-
|
|
95
|
-
<div class="info">
|
|
96
|
-
<h3>About Display P3 Enhanced Colors</h3>
|
|
97
|
-
<p>Display P3 is a wider color gamut that can display ~25% more colors than standard sRGB. The Pierre Vibrant themes use CSS <code>color(display-p3 r g b)</code> format with <strong>enhanced saturation</strong> to fully utilize the P3 color space.</p>
|
|
98
|
-
<p><strong>Enhancement:</strong> Colors are boosted by 15-30% saturation (depending on original saturation) and 5% luminance for highly saturated colors. This pushes colors into the wider P3 gamut that isn't available in sRGB.</p>
|
|
99
|
-
<p><strong>Important:</strong> To see the difference, you need a P3-capable display (most Macs from 2015+, iPhones, iPads).</p>
|
|
100
|
-
</div>
|
|
101
|
-
|
|
102
|
-
<div class="comparison-grid">
|
|
103
|
-
<div class="color-card">
|
|
104
|
-
<h3>Blue</h3>
|
|
105
|
-
<div class="label">Standard (sRGB)</div>
|
|
106
|
-
<div class="color-swatch srgb" style="background-color: #008cff;">
|
|
107
|
-
#008cff
|
|
108
|
-
</div>
|
|
109
|
-
<div class="label">Vibrant (Display P3 Enhanced)</div>
|
|
110
|
-
<div class="color-swatch p3" style="background-color: color(display-p3 0.267653 0.570512 1.000000);">
|
|
111
|
-
P3
|
|
112
|
-
</div>
|
|
113
|
-
<div class="hex-value">color(display-p3 0.267653 0.570512 1.000000)</div>
|
|
114
|
-
</div>
|
|
115
|
-
|
|
116
|
-
<div class="color-card">
|
|
117
|
-
<h3>Green</h3>
|
|
118
|
-
<div class="label">Standard (sRGB)</div>
|
|
119
|
-
<div class="color-swatch srgb" style="background-color: #0dbe4e;">
|
|
120
|
-
#0dbe4e
|
|
121
|
-
</div>
|
|
122
|
-
<div class="label">Vibrant (Display P3 Enhanced)</div>
|
|
123
|
-
<div class="color-swatch p3" style="background-color: color(display-p3 0.298067 0.776115 0.322484);">
|
|
124
|
-
P3
|
|
125
|
-
</div>
|
|
126
|
-
<div class="hex-value">color(display-p3 0.298067 0.776115 0.322484)</div>
|
|
127
|
-
</div>
|
|
128
|
-
|
|
129
|
-
<div class="color-card">
|
|
130
|
-
<h3>Red</h3>
|
|
131
|
-
<div class="label">Standard (sRGB)</div>
|
|
132
|
-
<div class="color-swatch srgb" style="background-color: #ff2e3f;">
|
|
133
|
-
#ff2e3f
|
|
134
|
-
</div>
|
|
135
|
-
<div class="label">Vibrant (Display P3 Enhanced)</div>
|
|
136
|
-
<div class="color-swatch p3" style="background-color: color(display-p3 1.000000 0.250216 0.262337);">
|
|
137
|
-
P3
|
|
138
|
-
</div>
|
|
139
|
-
<div class="hex-value">color(display-p3 1.000000 0.250216 0.262337)</div>
|
|
140
|
-
</div>
|
|
141
|
-
|
|
142
|
-
<div class="color-card">
|
|
143
|
-
<h3>Purple</h3>
|
|
144
|
-
<div class="label">Standard (sRGB)</div>
|
|
145
|
-
<div class="color-swatch srgb" style="background-color: #c635e4;">
|
|
146
|
-
#c635e4
|
|
147
|
-
</div>
|
|
148
|
-
<div class="label">Vibrant (Display P3 Enhanced)</div>
|
|
149
|
-
<div class="color-swatch p3" style="background-color: color(display-p3 0.770871 0.230698 0.945253);">
|
|
150
|
-
P3
|
|
151
|
-
</div>
|
|
152
|
-
<div class="hex-value">color(display-p3 0.770871 0.230698 0.945253)</div>
|
|
153
|
-
</div>
|
|
154
|
-
|
|
155
|
-
<div class="color-card">
|
|
156
|
-
<h3>Pink</h3>
|
|
157
|
-
<div class="label">Standard (sRGB)</div>
|
|
158
|
-
<div class="color-swatch srgb" style="background-color: #fc2b73;">
|
|
159
|
-
#fc2b73
|
|
160
|
-
</div>
|
|
161
|
-
<div class="label">Vibrant (Display P3 Enhanced)</div>
|
|
162
|
-
<div class="color-swatch p3" style="background-color: color(display-p3 0.995522 0.233444 0.460772);">
|
|
163
|
-
P3
|
|
164
|
-
</div>
|
|
165
|
-
<div class="hex-value">color(display-p3 0.995522 0.233444 0.460772)</div>
|
|
166
|
-
</div>
|
|
167
|
-
|
|
168
|
-
<div class="color-card">
|
|
169
|
-
<h3>Orange</h3>
|
|
170
|
-
<div class="label">Standard (sRGB)</div>
|
|
171
|
-
<div class="color-swatch srgb" style="background-color: #fe8c2c;">
|
|
172
|
-
#fe8c2c
|
|
173
|
-
</div>
|
|
174
|
-
<div class="label">Vibrant (Display P3 Enhanced)</div>
|
|
175
|
-
<div class="color-swatch p3" style="background-color: color(display-p3 1.000000 0.598672 0.265916);">
|
|
176
|
-
P3
|
|
177
|
-
</div>
|
|
178
|
-
<div class="hex-value">color(display-p3 1.000000 0.598672 0.265916)</div>
|
|
179
|
-
</div>
|
|
180
|
-
|
|
181
|
-
<div class="color-card">
|
|
182
|
-
<h3>Cyan</h3>
|
|
183
|
-
<div class="label">Standard (sRGB)</div>
|
|
184
|
-
<div class="color-swatch srgb" style="background-color: #08c0ef;">
|
|
185
|
-
#08c0ef
|
|
186
|
-
</div>
|
|
187
|
-
<div class="label">Vibrant (Display P3 Enhanced)</div>
|
|
188
|
-
<div class="color-swatch p3" style="background-color: color(display-p3 0.327292 0.790977 0.995660);">
|
|
189
|
-
P3
|
|
190
|
-
</div>
|
|
191
|
-
<div class="hex-value">color(display-p3 0.327292 0.790977 0.995660)</div>
|
|
192
|
-
</div>
|
|
193
|
-
|
|
194
|
-
<div class="color-card">
|
|
195
|
-
<h3>Teal</h3>
|
|
196
|
-
<div class="label">Standard (sRGB)</div>
|
|
197
|
-
<div class="color-swatch srgb" style="background-color: #00c5d2;">
|
|
198
|
-
#00c5d2
|
|
199
|
-
</div>
|
|
200
|
-
<div class="label">Vibrant (Display P3 Enhanced)</div>
|
|
201
|
-
<div class="color-swatch p3" style="background-color: color(display-p3 0.342284 0.816699 0.877157);">
|
|
202
|
-
P3
|
|
203
|
-
</div>
|
|
204
|
-
<div class="hex-value">color(display-p3 0.342284 0.816699 0.877157)</div>
|
|
205
|
-
</div>
|
|
206
|
-
</div>
|
|
207
|
-
|
|
208
|
-
<div class="info">
|
|
209
|
-
<h3>Browser Support</h3>
|
|
210
|
-
<p>CSS <code>color(display-p3 ...)</code> is supported in:</p>
|
|
211
|
-
<ul>
|
|
212
|
-
<li>Safari 10+ (macOS and iOS)</li>
|
|
213
|
-
<li>Chrome 111+</li>
|
|
214
|
-
<li>Firefox 113+</li>
|
|
215
|
-
<li>Edge 111+</li>
|
|
216
|
-
</ul>
|
|
217
|
-
<p>Browsers without P3 support will automatically fall back to the closest sRGB color.</p>
|
|
218
|
-
</div>
|
|
219
|
-
|
|
220
|
-
<script>
|
|
221
|
-
// Check for P3 support
|
|
222
|
-
const supportsP3 = window.matchMedia('(color-gamut: p3)').matches;
|
|
223
|
-
const statusEl = document.getElementById('p3-status');
|
|
224
|
-
|
|
225
|
-
if (supportsP3) {
|
|
226
|
-
statusEl.innerHTML = '<span class="supports">✓</span> Your display supports Display P3! You should see more vibrant colors in the P3 swatches above. Compare the top and bottom colors in each card.';
|
|
227
|
-
statusEl.style.borderLeft = '4px solid color(display-p3 0.340 0.734 0.360)';
|
|
228
|
-
} else {
|
|
229
|
-
statusEl.innerHTML = '<span class="no-support">✗</span> Your display does not support Display P3, or your browser doesn\'t support the color(display-p3) syntax. The P3 colors will appear similar to the standard sRGB colors.';
|
|
230
|
-
statusEl.style.borderLeft = '4px solid #ff6762';
|
|
231
|
-
}
|
|
232
|
-
</script>
|
|
233
|
-
</body>
|
|
234
|
-
</html>
|