From 7d28376cece1fa1f82cb1594ea6e975612e70ca0 Mon Sep 17 00:00:00 2001 From: Oliver Date: Tue, 10 Feb 2026 23:04:49 -0700 Subject: [PATCH] Update the save changes button to be more inline with the rest of Foundry --- assets/icons/save.svg | 1 + styles/apps/StatusEffectIconConfig.css | 25 ++++++++++++++++++++ styles/components/icon.css | 23 ++++++++++++++++++ styles/components/svg-loader.css | 22 +++++++++++++++++ templates/StatusEffectIconConfig/effects.hbs | 8 ++++--- templates/StatusEffectIconConfig/footer.hbs | 12 +++++++--- 6 files changed, 85 insertions(+), 6 deletions(-) create mode 100644 assets/icons/save.svg create mode 100644 styles/components/icon.css create mode 100644 styles/components/svg-loader.css diff --git a/assets/icons/save.svg b/assets/icons/save.svg new file mode 100644 index 0000000..da68b4f --- /dev/null +++ b/assets/icons/save.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/styles/apps/StatusEffectIconConfig.css b/styles/apps/StatusEffectIconConfig.css index 4298e7c..0a247dc 100644 --- a/styles/apps/StatusEffectIconConfig.css +++ b/styles/apps/StatusEffectIconConfig.css @@ -1,4 +1,25 @@ .oft.StatusEffectIconConfig { + > .window-content { + gap: 1rem; + } + + footer { + display: flex; + flex-direction: row; + + > * { + flex-grow: 1; + } + + button { + display: flex; + flex-direction: row; + gap: 8px; + height: initial; + padding: 8px 16px; + } + } + .effect-list { list-style-type: none; padding: 0; @@ -8,6 +29,10 @@ gap: 16px; } + .placeholder { + font-style: italic; + } + .effect { display: flex; flex-direction: row; diff --git a/styles/components/icon.css b/styles/components/icon.css new file mode 100644 index 0000000..31ddda5 --- /dev/null +++ b/styles/components/icon.css @@ -0,0 +1,23 @@ +:host { + display: inline-block; +} + +div { + display: flex; + justify-content: center; + align-items: center; + width: 100%; + height: 100%; +} + +svg { + width: var(--size, 1rem); + height: var(--size, 1rem); + fill: var(--fill); +} + +path { + stroke: var(--stroke); + stroke-width: var(--stroke-width); + stroke-linejoin: var(--stroke-linejoin); +} diff --git a/styles/components/svg-loader.css b/styles/components/svg-loader.css new file mode 100644 index 0000000..b843bc5 --- /dev/null +++ b/styles/components/svg-loader.css @@ -0,0 +1,22 @@ +:host { + display: inline-block; +} + +div { + display: flex; + justify-content: center; + align-items: center; + width: 100%; + height: 100%; +} + +svg { + fill: var(--fill); + stroke: var(--stroke); +} + +path { + stroke: var(--stroke); + stroke-width: var(--stroke-width); + stroke-linejoin: var(--stroke-linejoin); +} diff --git a/templates/StatusEffectIconConfig/effects.hbs b/templates/StatusEffectIconConfig/effects.hbs index dffda0e..46946ef 100644 --- a/templates/StatusEffectIconConfig/effects.hbs +++ b/templates/StatusEffectIconConfig/effects.hbs @@ -1,4 +1,4 @@ -
+
{{#if effects}}
    {{#each effects as | effect |}} @@ -37,6 +37,8 @@ {{/each}}
{{else}} - {{ localize "OFT.apps.StatusEffectIconConfig.no-status-effects" }} +
+ {{ localize "OFT.apps.StatusEffectIconConfig.no-status-effects" }} +
{{/if}} -
+ diff --git a/templates/StatusEffectIconConfig/footer.hbs b/templates/StatusEffectIconConfig/footer.hbs index 895d733..54f5fff 100644 --- a/templates/StatusEffectIconConfig/footer.hbs +++ b/templates/StatusEffectIconConfig/footer.hbs @@ -1,5 +1,11 @@ -
+
+