mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
(core) Improving experience when editing group-by column.
Summary: Improving experience when editing group-by column: - Disable column rename - Allow changing most widget properties: - Color/Background - Number format - Date/DateTime format (but not the timezone) - All toggle options (for toggle column) - Remove Edit button on Choice Edit - Changing the underlying column should reset all those options back to the original column. Test Plan: nbrowser Reviewers: alexmojaki Reviewed By: alexmojaki Subscribers: alexmojaki Differential Revision: https://phab.getgrist.com/D3216
This commit is contained in:
@@ -58,7 +58,8 @@ export function buildNameConfig(owner: MultiHolder, origColumn: ColumnRec, curso
|
||||
cssColTieConnectors(),
|
||||
cssToggleButton(icon('FieldReference'),
|
||||
cssToggleButton.cls('-selected', (use) => !use(untieColId)),
|
||||
dom.on('click', () => untieColId.saveOnly(!untieColId.peek())),
|
||||
dom.on('click', () => !origColumn.disableModify.peek() && untieColId.saveOnly(!untieColId.peek())),
|
||||
cssToggleButton.cls("-disabled", origColumn.disableModify),
|
||||
testId('field-derive-id')
|
||||
),
|
||||
)
|
||||
@@ -391,6 +392,10 @@ const cssToggleButton = styled(cssIconButton, `
|
||||
&-selected:hover {
|
||||
--icon-color: ${colors.darkGrey};
|
||||
}
|
||||
&-disabled, &-disabled:hover {
|
||||
--icon-color: ${colors.light};
|
||||
background-color: var(--grist-color-medium-grey-opaque);
|
||||
}
|
||||
`);
|
||||
|
||||
const cssColLabelBlock = styled('div', `
|
||||
|
||||
Reference in New Issue
Block a user