Add picker to sticky columns

This commit is contained in:
Adria Navarro 2024-05-29 16:21:19 +02:00
parent 06549149b6
commit 5b42aff1f7
2 changed files with 18 additions and 1 deletions

View File

@ -57,6 +57,7 @@
class:fullWidth class:fullWidth
class="spectrum-ActionButton spectrum-ActionButton--size{size}" class="spectrum-ActionButton spectrum-ActionButton--size{size}"
class:active class:active
class:disabled
{disabled} {disabled}
on:longPress on:longPress
on:click|preventDefault on:click|preventDefault
@ -122,6 +123,9 @@
.is-selected:not(.emphasized) .spectrum-Icon { .is-selected:not(.emphasized) .spectrum-Icon {
color: var(--spectrum-global-color-gray-900); color: var(--spectrum-global-color-gray-900);
} }
.is-selected.disabled .spectrum-Icon {
color: var(--spectrum-global-color-gray-500);
}
.tooltip { .tooltip {
position: absolute; position: absolute;
pointer-events: none; pointer-events: none;

View File

@ -64,7 +64,19 @@
<Icon size="S" name={getColumnIcon($stickyColumn)} /> <Icon size="S" name={getColumnIcon($stickyColumn)} />
{$stickyColumn.label} {$stickyColumn.label}
</div> </div>
<Toggle disabled size="S" value={true} />
<div class="permissionPicker">
{#each options as option}
<ActionButton
disabled
size="S"
icon={option.icon}
quiet
selected={option.value === PERMISSION_OPTIONS.WRITABLE}
noPadding
/>
{/each}
</div>
{/if} {/if}
{#each $columns as column} {#each $columns as column}
<div class="column"> <div class="column">
@ -99,6 +111,7 @@
display: grid; display: grid;
align-items: center; align-items: center;
grid-template-columns: 1fr auto; grid-template-columns: 1fr auto;
gap: 8px;
} }
.columns :global(.spectrum-Switch) { .columns :global(.spectrum-Switch) {
margin-right: 0; margin-right: 0;