Permalinks for seed colors

This commit is contained in:
Lea Verou
2025-02-27 19:31:17 -05:00
parent 27af62591f
commit bc170cce15

View File

@@ -118,6 +118,10 @@ let paletteAppSpec = {
}
}
if (this.permalink.has('color')) {
this.seedColors = this.permalink.getAll('color');
}
if (this.permalink.has('uid')) {
this.uid = Number(this.permalink.get('uid'));
}
@@ -492,6 +496,14 @@ let paletteAppSpec = {
this.permalink.set('gray-chroma', this.grayChroma, this.originalGrayChroma);
},
seedColors: {
deep: true,
handler() {
this.permalink.set('color', this.seedColors);
this.permalink.updateLocation();
},
},
tweaks: {
deep: true,
async handler(value, oldValue) {