very productive day 😐

This commit is contained in:
nvms 2024-10-22 15:00:04 -04:00
parent bceca3053c
commit 9d90e12f8a
5 changed files with 10 additions and 5 deletions

View File

@ -1265,7 +1265,8 @@ function flattenRefs(scope) {
var main = {
template: html`
<div class="sans-serif margin-y-3 container" style="--column-gap: .5rem; --row-gap: .5rem;">
<h1 class="f1 margin-bottom-1 color-5">Colors</h1>
<h1 class="f1 margin-bottom-1 color-60">phase</h1>
<h2 class="f3 margin-bottom-1 color-peach-50">Colors</h2>
<grid columns="6" class="f6 white-space-nowrap">
<div :for="variant in ['base', 'accent', 'red', 'rose', 'orange', 'amber', 'yellow', 'lime', 'green', 'emerald', 'teal', 'cyan', 'sky', 'blue', 'indigo', 'lavender', 'violet', 'purple', 'plum', 'fuchsia', 'pink', 'peach']" class="border-color-30 border-2px">
<div :for="rank, index in ranks">

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -251,7 +251,8 @@ import { html } from "./util";
const main = {
template: html`
<div class="sans-serif margin-y-3 container" style="--column-gap: .5rem; --row-gap: .5rem;">
<h1 class="f1 margin-bottom-1 color-5">Colors</h1>
<h1 class="f1 margin-bottom-1 color-60">phase</h1>
<h2 class="f3 margin-bottom-1 color-peach-50">Colors</h2>
<grid columns="6" class="f6 white-space-nowrap">
<div :for="variant in ['base', 'accent', 'red', 'rose', 'orange', 'amber', 'yellow', 'lime', 'green', 'emerald', 'teal', 'cyan', 'sky', 'blue', 'indigo', 'lavender', 'violet', 'purple', 'plum', 'fuchsia', 'pink', 'peach']" class="border-color-30 border-2px">
<div :for="rank, index in ranks">

View File

@ -136,7 +136,9 @@ export const createScopedContext = (ctx: Context, data = {}): Context => {
const parentScope = ctx.scope;
const mergedScope = Object.create(parentScope);
Object.defineProperties(mergedScope, Object.getOwnPropertyDescriptors(data));
let proxy: any;
proxy = reactive(
new Proxy(mergedScope, {
set(target, key, val, receiver) {
@ -145,6 +147,7 @@ export const createScopedContext = (ctx: Context, data = {}): Context => {
if (receiver === proxy && !target.hasOwnProperty(key)) {
return Reflect.set(parentScope, key, val);
}
return Reflect.set(target, key, val, receiver);
},
}),