Skip to content

Commit

Permalink
use WdsTextInput
Browse files Browse the repository at this point in the history
fix pick fields

adapt BuilderSelect

improve settings handler modal

move help button
  • Loading branch information
madeindjs committed Dec 3, 2024
1 parent 0f8a653 commit 02a1d02
Show file tree
Hide file tree
Showing 15 changed files with 487 additions and 516 deletions.
70 changes: 31 additions & 39 deletions src/ui/src/builder/BuilderFieldsAlign.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,38 +5,36 @@
tabindex="-1"
:data-automation-key="props.fieldKey"
>
<div class="chipStackContainer">
<div class="chipStack">
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'default' }"
@click="
() => {
setMode('default');
setContentValue(component.id, fieldKey, undefined);
}
"
>
Default
</button>
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'css' }"
@click="setMode('css')"
>
CSS
</button>
<button
class="chip"
:class="{ active: mode == 'pick' }"
tabindex="0"
@click="setMode('pick')"
>
Pick
</button>
</div>
<div class="chipStack">
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'default' }"
@click="
() => {
setMode('default');
setContentValue(component.id, fieldKey, undefined);
}
"
>
Default
</button>
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'css' }"
@click="setMode('css')"
>
CSS
</button>
<button
class="chip"
:class="{ active: mode == 'pick' }"
tabindex="0"
@click="setMode('pick')"
>
Pick
</button>
</div>

<div v-if="mode == 'pick' || mode == 'css'" class="main">
Expand Down Expand Up @@ -263,13 +261,7 @@ onBeforeUnmount(() => {
<style scoped>
@import "./sharedStyles.css";
.chipStackContainer {
padding: 12px;
margin-top: 4px;
padding-bottom: 12px;
}
.main {
border-top: 1px solid var(--builderSeparatorColor);
padding: 12px;
padding-top: 12px;
}
</style>
75 changes: 36 additions & 39 deletions src/ui/src/builder/BuilderFieldsColor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,38 +5,36 @@
tabindex="-1"
:data-automation-key="fieldKey"
>
<div class="chipStackContainer">
<div class="chipStack">
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'default' }"
@click="
() => {
setMode('default');
setContentValue(component.id, fieldKey, undefined);
}
"
>
Default
</button>
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'css' }"
@click="setMode('css')"
>
CSS
</button>
<button
class="chip"
:class="{ active: mode == 'pick' }"
tabindex="0"
@click="setMode('pick')"
>
Pick
</button>
</div>
<div class="chipStack">
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'default' }"
@click="
() => {
setMode('default');
setContentValue(component.id, fieldKey, undefined);
}
"
>
Default
</button>
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'css' }"
@click="setMode('css')"
>
CSS
</button>
<button
class="chip"
:class="{ active: mode == 'pick' }"
tabindex="0"
@click="setMode('pick')"
>
Pick
</button>
</div>

<div v-if="mode == 'pick' || mode == 'css'" class="main">
Expand Down Expand Up @@ -144,13 +142,12 @@ onBeforeUnmount(() => {
<style scoped>
@import "./sharedStyles.css";
.chipStackContainer {
padding: 12px;
margin-top: 4px;
padding-bottom: 12px;
}
.main {
border-top: 1px solid var(--builderSeparatorColor);
padding: 12px;
padding-top: 6px;
}
input[type="color"] {
width: 100%;
height: 40px;
}
</style>
3 changes: 0 additions & 3 deletions src/ui/src/builder/BuilderFieldsKeyValue.vue
Original file line number Diff line number Diff line change
Expand Up @@ -192,9 +192,6 @@ onMounted(async () => {
@import "./sharedStyles.css";
.chipStackContainer {
padding: 12px;
margin-top: 4px;
padding-bottom: 12px;
border-bottom: 1px solid var(--builderSeparatorColor);
}
Expand Down
68 changes: 30 additions & 38 deletions src/ui/src/builder/BuilderFieldsPadding.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,38 +5,36 @@
tabindex="-1"
:data-automation-key="props.fieldKey"
>
<div class="chipStackContainer">
<div class="chipStack">
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'default' }"
@click="
() => {
setMode('default');
setContentValue(component.id, fieldKey, undefined);
}
"
>
Default
</button>
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'css' }"
@click="setMode('css')"
>
CSS
</button>
<button
class="chip"
:class="{ active: mode == 'pick' }"
tabindex="0"
@click="setMode('pick')"
>
Pick
</button>
</div>
<div class="chipStack">
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'default' }"
@click="
() => {
setMode('default');
setContentValue(component.id, fieldKey, undefined);
}
"
>
Default
</button>
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'css' }"
@click="setMode('css')"
>
CSS
</button>
<button
class="chip"
:class="{ active: mode == 'pick' }"
tabindex="0"
@click="setMode('pick')"
>
Pick
</button>
</div>

<div v-if="mode == 'pick' || mode == 'css'" class="main">
Expand Down Expand Up @@ -391,12 +389,6 @@ onBeforeUnmount(() => {
@import "./sharedStyles.css";
@import "./ico.css";
.chipStackContainer {
padding: 12px;
margin-top: 4px;
padding-bottom: 12px;
}
.main {
border-top: 1px solid var(--builderSeparatorColor);
padding: 12px;
Expand Down
67 changes: 30 additions & 37 deletions src/ui/src/builder/BuilderFieldsShadow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,38 +5,36 @@
tabindex="-1"
:data-automation-key="props.fieldKey"
>
<div class="chipStackContainer">
<div class="chipStack">
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'default' }"
@click="
() => {
setMode('default');
setContentValue(component.id, fieldKey, undefined);
}
"
>
Default
</button>
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'css' }"
@click="setMode('css')"
>
CSS
</button>
<button
class="chip"
:class="{ active: mode == 'pick' }"
tabindex="0"
@click="setMode('pick')"
>
Pick
</button>
</div>
<div class="chipStack">
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'default' }"
@click="
() => {
setMode('default');
setContentValue(component.id, fieldKey, undefined);
}
"
>
Default
</button>
<button
class="chip"
tabindex="0"
:class="{ active: mode == 'css' }"
@click="setMode('css')"
>
CSS
</button>
<button
class="chip"
:class="{ active: mode == 'pick' }"
tabindex="0"
@click="setMode('pick')"
>
Pick
</button>
</div>

<div v-if="mode == 'pick' || mode == 'css'" class="main">
Expand Down Expand Up @@ -236,11 +234,6 @@ onBeforeUnmount(() => {
<style scoped>
@import "./sharedStyles.css";
.chipStackContainer {
padding: 12px;
margin-top: 4px;
padding-bottom: 12px;
}
.main {
border-top: 1px solid var(--builderSeparatorColor);
padding: 12px;
Expand Down
1 change: 0 additions & 1 deletion src/ui/src/builder/BuilderFieldsText.vue
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ const handleInput = (ev: Event) => {

<style>
.BuilderFieldsText .content {
padding: 16px 12px 12px 12px;
width: 100%;
}
</style>
Expand Down
Loading

0 comments on commit 02a1d02

Please sign in to comment.