Skip to content

πŸ”₯ πŸ”₯ πŸ”₯ A Free & Self-hostable Airtable Alternative

fix(nc-gui): expanded form style

Ramesh Manedd70d53972eb
diff --git a/packages/nc-gui/assets/css/theme-overrides.scss b/packages/nc-gui/assets/css/theme-overrides.scss
index 8ff4826d50..908b77a97d 100644
--- a/packages/nc-gui/assets/css/theme-overrides.scss
+++ b/packages/nc-gui/assets/css/theme-overrides.scss
@@ -7,10 +7,12 @@ body {
}
// Dropdown
-.ant-dropdown,
-.ant-tabs-dropdown,
+.ant-dropdown {
+ @apply !bg-nc-bg-default text-nc-content-gray;
+}
+
.ant-tabs-dropdown-menu {
- @apply !bg-nc-bg-default !text-nc-content-gray;
+ @apply bg-nc-bg-default text-nc-content-gray;
}
// Drawer & Modal
@@ -19,6 +21,11 @@ body {
@apply !bg-nc-bg-default;
}
+.ant-drawer,
+.ant-modal {
+ @apply text-nc-content-gray;
+}
+
// Dropdown Menu
.ant-dropdown-menu.ant-dropdown-menu-root {
@apply !bg-nc-bg-default !text-nc-content-gray;
diff --git a/packages/nc-gui/assets/nc-icons-v2/nc-node.svg b/packages/nc-gui/assets/nc-icons-v2/nc-node.svg
index 0c23343e31..102897c992 100644
--- a/packages/nc-gui/assets/nc-icons-v2/nc-node.svg
+++ b/packages/nc-gui/assets/nc-icons-v2/nc-node.svg
@@ -1,6 +1,6 @@
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
-<rect width="16" height="16" fill="white"/>
-<path d="M11.3398 8H15.3065" stroke="#6A7184" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
-<path d="M0.700195 8H4.66686" stroke="#6A7184" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
-<path d="M8.00016 10.6673C9.47292 10.6673 10.6668 9.47341 10.6668 8.00065C10.6668 6.52789 9.47292 5.33398 8.00016 5.33398C6.5274 5.33398 5.3335 6.52789 5.3335 8.00065C5.3335 9.47341 6.5274 10.6673 8.00016 10.6673Z" fill="white" stroke="#6A7184" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
+<rect width="16" height="16" fill="transparent"/>
+<path d="M11.3398 8H15.3065" stroke="currentColor" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
+<path d="M0.700195 8H4.66686" stroke="currentColor" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
+<path d="M8.00016 10.6673C9.47292 10.6673 10.6668 9.47341 10.6668 8.00065C10.6668 6.52789 9.47292 5.33398 8.00016 5.33398C6.5274 5.33398 5.3335 6.52789 5.3335 8.00065C5.3335 9.47341 6.5274 10.6673 8.00016 10.6673Z" fill="transparent" stroke="currentColor" stroke-width="1.33333" stroke-linecap="round" stroke-linejoin="round"/>
</svg>
diff --git a/packages/nc-gui/components/cell/attachment/index.vue b/packages/nc-gui/components/cell/attachment/index.vue
index 8c943d89cc..77f78b28f2 100644
--- a/packages/nc-gui/components/cell/attachment/index.vue
+++ b/packages/nc-gui/components/cell/attachment/index.vue
@@ -379,7 +379,7 @@ onUnmounted(() => {
>
<template #entity-preview>
<span>
- <div class="flex flex-row items-center py-2.25 px-2.5 bg-gray-50 rounded-lg text-gray-700 mb-4">
+ <div class="flex flex-row items-center py-2.25 px-2.5 bg-nc-bg-gray-extralight rounded-lg text-nc-content-gray-subtle mb-4">
<GeneralIcon icon="file" class="nc-view-icon"></GeneralIcon>
<div
class="capitalize text-ellipsis overflow-hidden select-none w-full pl-1.75"
diff --git a/packages/nc-gui/components/general/DeleteModal.vue b/packages/nc-gui/components/general/DeleteModal.vue
index 7c22ddcfcb..75202f72f4 100644
--- a/packages/nc-gui/components/general/DeleteModal.vue
+++ b/packages/nc-gui/components/general/DeleteModal.vue
@@ -61,9 +61,9 @@ watch(visible, (value) => {
<template>
<GeneralModal v-model:visible="visible" size="small" centered>
<div ref="modalRef" class="flex flex-col p-6">
- <div class="flex flex-row pb-2 mb-3 font-medium text-lg text-gray-800">{{ deleteLabel }} {{ props.entityName }}</div>
+ <div class="flex flex-row pb-2 mb-3 font-medium text-lg text-nc-content-gray">{{ deleteLabel }} {{ props.entityName }}</div>
- <div v-if="showDefaultDeleteMsg" class="mb-3 text-gray-800">
+ <div v-if="showDefaultDeleteMsg" class="mb-3 text-nc-content-gray">
{{
$t('msg.areYouSureUWantToDeleteLabel', {
deleteLabel: deleteLabel.toLowerCase(),
diff --git a/packages/nc-gui/components/nc/DropdownSelect.vue b/packages/nc-gui/components/nc/DropdownSelect.vue
index e0b946bb25..716eddbd2c 100644
--- a/packages/nc-gui/components/nc/DropdownSelect.vue
+++ b/packages/nc-gui/components/nc/DropdownSelect.vue
@@ -31,9 +31,9 @@ export default {
<div
v-for="item of props.items"
:key="item.value"
- class="flex items-center justify-between px-2 py-1 rounded-md transition-colors hover:bg-gray-100 cursor-pointer"
+ class="flex items-center justify-between px-2 py-1 rounded-md transition-colors hover:bg-nc-bg-gray-light cursor-pointer"
:class="{
- 'bg-gray-100': modelValue === item.value,
+ 'bg-nc-bg-gray-light': modelValue === item.value,
}"
@click="modelValue = item.value"
>
diff --git a/packages/nc-gui/components/nc/Menu/Item.vue b/packages/nc-gui/components/nc/Menu/Item.vue
index 9048b2c36a..d961dbe64a 100644
--- a/packages/nc-gui/components/nc/Menu/Item.vue
+++ b/packages/nc-gui/components/nc/Menu/Item.vue
@@ -17,6 +17,7 @@ defineProps<{
style?: StyleValue
disabled?: boolean | number
innerClass?: string
+ danger?: boolean
}>()
defineOptions({
@@ -26,7 +27,15 @@ defineOptions({
<template>
<div class="w-full" :style="style">
- <a-menu-item :key="mKey" v-bind="$attrs" :disabled="Boolean(disabled)" class="nc-menu-item">
+ <a-menu-item
+ :key="mKey"
+ v-bind="$attrs"
+ :disabled="Boolean(disabled)"
+ class="nc-menu-item"
+ :class="{
+ 'nc-menu-item-danger': danger,
+ }"
+ >
<div class="nc-menu-item-inner" :class="innerClass">
<slot />
</div>
@@ -43,6 +52,12 @@ defineOptions({
@apply flex flex-row items-center gap-x-2 text-sm;
}
+.nc-menu-item.nc-menu-item-danger {
+ &:not(.ant-dropdown-menu-item-disabled) {
+ @apply !text-nc-content-red-medium !hover:bg-nc-bg-red-light;
+ }
+}
+
.nc-menu-item > .ant-dropdown-menu-title-content {
// Not Icon
:not(.nc-icon):not(.material-symbols) {
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/RichComment.vue b/packages/nc-gui/components/smartsheet/expanded-form/RichComment.vue
index fbc7dae016..66042217d3 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/RichComment.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/RichComment.vue
@@ -319,7 +319,7 @@ defineExpose({
<NcButton
v-e="['a:row-expand:comment:save']"
:disabled="!vModel?.length"
- class="!disabled:bg-gray-100 nc-comment-save-btn !h-7 !w-7 !shadow-none"
+ class="!disabled:bg-nc-bg-gray-light nc-comment-save-btn !h-7 !w-7 !shadow-none"
size="xsmall"
@click="saveComment"
>
@@ -342,7 +342,7 @@ defineExpose({
}
.nc-rich-link-tooltip {
- @apply text-gray-500;
+ @apply text-nc-content-gray-muted;
}
.nc-comment-rich-editor {
@@ -368,7 +368,7 @@ defineExpose({
}
}
.tiptap p.is-editor-empty:first-child::before {
- @apply text-gray-500;
+ @apply text-nc-content-gray-muted;
content: attr(data-placeholder);
float: left;
height: 0;
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/RichTextOptions.vue b/packages/nc-gui/components/smartsheet/expanded-form/RichTextOptions.vue
index ea3535ad47..f416eee59e 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/RichTextOptions.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/RichTextOptions.vue
@@ -103,7 +103,7 @@ const newMentionNode = () => {
<NcButton
:class="{ 'is-active': editor?.isActive('bold') }"
:tabindex="tabIndex"
- class="!h-7 !w-7 !hover:bg-gray-200"
+ class="!h-7 !w-7 !hover:bg-nc-bg-gray-medium"
size="xsmall"
type="text"
@click="editor?.chain().focus().toggleBold().run()"
@@ -124,7 +124,7 @@ const newMentionNode = () => {
<NcButton
:class="{ 'is-active': editor?.isActive('italic') }"
:tabindex="tabIndex"
- class="!h-7 !w-7 !hover:bg-gray-200"
+ class="!h-7 !w-7 !hover:bg-nc-bg-gray-medium"
size="xsmall"
type="text"
@click=";(editor?.chain().focus() as any).toggleItalic().run()"
@@ -145,7 +145,7 @@ const newMentionNode = () => {
<NcButton
:class="{ 'is-active': editor?.isActive('underline') }"
:tabindex="tabIndex"
- class="!h-7 !w-7 !hover:bg-gray-200"
+ class="!h-7 !w-7 !hover:bg-nc-bg-gray-medium"
size="xsmall"
type="text"
@click="editor?.chain().focus().toggleUnderline().run()"
@@ -165,7 +165,7 @@ const newMentionNode = () => {
<NcButton
:class="{ 'is-active': editor?.isActive('strike') }"
:tabindex="tabIndex"
- class="!h-7 !w-7 !hover:bg-gray-200"
+ class="!h-7 !w-7 !hover:bg-nc-bg-gray-medium"
size="xsmall"
type="text"
@click="editor?.chain().focus().toggleStrike().run()"
@@ -179,7 +179,7 @@ const newMentionNode = () => {
<NcButton
:class="{ 'is-active': editor?.isActive('link') }"
:tabindex="tabIndex"
- class="!h-7 !w-7 !hover:bg-gray-200"
+ class="!h-7 !w-7 !hover:bg-nc-bg-gray-medium"
size="xsmall"
type="text"
@click="onToggleLink"
@@ -199,7 +199,7 @@ const newMentionNode = () => {
<NcButton
:class="{ 'is-active': editor?.isActive('suggestions') }"
:tabindex="tabIndex"
- class="!h-7 !w-7 !hover:bg-gray-200"
+ class="!h-7 !w-7 !hover:bg-nc-bg-gray-medium"
size="xsmall"
type="text"
@click="newMentionNode"
@@ -215,7 +215,7 @@ const newMentionNode = () => {
@apply !border-none;
.nc-button.is-active {
- @apply text-brand-500;
+ @apply text-nc-content-brand;
outline: 1px;
}
.ant-select-selector {
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/AuditMiniItem.vue b/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/AuditMiniItem.vue
index 97b5b4bbbd..bd4c074bf9 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/AuditMiniItem.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/AuditMiniItem.vue
@@ -123,7 +123,7 @@ function shouldShowRaw(key: string) {
<template>
<div v-for="columnKey of columnKeys" :key="columnKey" class="py-2 px-3">
- <div class="flex items-center gap-1 !text-gray-600 text-xs font-weight-500 nc-audit-mini-item-header">
+ <div class="flex items-center gap-1 !text-nc-content-gray-subtle2 text-xs font-weight-500 nc-audit-mini-item-header">
<SmartsheetHeaderCellIcon
:column-meta="{ uidt: meta[columnKey]?.type, dt: meta[columnKey]?.type === 'Number' ? 'bigint' : undefined }"
class="!m-0"
@@ -138,12 +138,12 @@ function shouldShowRaw(key: string) {
</div>
<div class="flex items-center gap-2 mt-3 flex-wrap">
<template v-if="meta[columnKey]?.type === 'Attachment'">
- <div v-if="processOldDataFor(columnKey)?.length > 0" class="border-1 border-red-500 rounded-md bg-red-50 w-full p-0.5">
+ <div v-if="processOldDataFor(columnKey)?.length > 0" class="border-1 border-nc-border-red rounded-md bg-nc-bg-red-light w-full p-0.5">
<div class="flex flex-col items-start gap-0.5">
<div
v-for="(item, i) of processOldDataFor(columnKey)"
:key="item.url || item.title"
- class="border-1 border-gray-200 rounded-md bg-white w-full"
+ class="border-1 border-nc-border-gray-medium rounded-md bg-nc-bg-default w-full"
>
<div class="flex items-center gap-2 w-full">
<div class="flex items-center justify-center w-8 aspect-square">
@@ -157,10 +157,10 @@ function shouldShowRaw(key: string) {
<CellAttachmentIconView :item="item" class="!w-8 !h-8" />
</div>
</div>
- <span class="w-0 flex-1 truncate text-small1 font-weight-500 text-gray-600">
+ <span class="w-0 flex-1 truncate text-small1 font-weight-500 text-nc-content-gray-subtle2">
{{ item.title }}
</span>
- <span class="text-xs font-weight-500 p-2 text-gray-500">
+ <span class="text-xs font-weight-500 p-2 text-nc-content-gray-muted">
{{ getReadableFileSize(item.size) }}
</span>
</div>
@@ -169,13 +169,13 @@ function shouldShowRaw(key: string) {
</div>
<div
v-if="processNewDataFor(columnKey)?.length > 0"
- class="border-1 border-green-500 rounded-md bg-green-50 w-full p-0.5"
+ class="border-1 border-nc-border-green rounded-md bg-nc-bg-green-light w-full p-0.5"
>
<div class="flex flex-col items-start gap-0.5">
<div
v-for="(item, i) of processNewDataFor(columnKey)"
:key="item.url || item.title"
- class="border-1 border-gray-200 rounded-md bg-white w-full"
+ class="border-1 border-nc-border-gray-medium rounded-md bg-nc-bg-default w-full"
>
<div class="flex items-center gap-2 w-full">
<div class="flex items-center justify-center w-8 aspect-square">
@@ -189,10 +189,10 @@ function shouldShowRaw(key: string) {
<CellAttachmentIconView :item="item" class="!w-8 !h-8" />
</div>
</div>
- <span class="w-0 flex-1 truncate text-small1 font-weight-500 text-gray-600">
+ <span class="w-0 flex-1 truncate text-small1 font-weight-500 text-nc-content-gray-subtle2">
{{ item.title }}
</span>
- <span class="text-xs font-weight-500 p-2 text-gray-500">
+ <span class="text-xs font-weight-500 p-2 text-nc-content-gray-muted">
{{ getReadableFileSize(item.size) }}
</span>
</div>
@@ -203,13 +203,13 @@ function shouldShowRaw(key: string) {
<template v-else-if="shouldShowRaw(columnKey)">
<div
v-if="isShowableValue(oldData[columnKey])"
- class="text-small1 text-red-700 border-1 border-red-200 rounded-md px-1 bg-red-50 line-through break-all"
+ class="text-small1 text-nc-content-red-dark border-1 border-nc-red-200 rounded-md px-1 bg-nc-bg-red-light line-through break-all"
>
{{ oldData[columnKey] }}
</div>
<div
v-if="isShowableValue(newData[columnKey])"
- class="text-small1 text-green-700 border-1 border-green-200 rounded-md px-1 bg-green-50 break-all"
+ class="text-small1 text-nc-content-green-dark border-1 border-nc-green-200 rounded-md px-1 bg-nc-bg-green-light break-all"
>
{{ newData[columnKey] }}
</div>
@@ -219,13 +219,13 @@ function shouldShowRaw(key: string) {
<template v-for="(block, i) of diffTextBlocks(oldData[columnKey] || '', newData[columnKey] || '')" :key="i">
<span
v-if="block.op === 'removed'"
- class="max-w-full text-small1 text-red-700 border-1 border-red-200 rounded-md px-1 mr-1 bg-red-50 line-through decoration-clone"
+ class="max-w-full text-small1 text-nc-content-red-dark border-1 border-nc-red-200 rounded-md px-1 mr-1 bg-nc-bg-red-light line-through decoration-clone"
>
{{ block.text }}
</span>
<span
v-else-if="block.op === 'added'"
- class="max-w-full text-small1 text-green-700 border-1 border-green-200 rounded-md px-1 mr-1 bg-green-50 decoration-clone"
+ class="max-w-full text-small1 text-nc-content-green-dark border-1 border-nc-green-200 rounded-md px-1 mr-1 bg-nc-bg-green-light decoration-clone"
>
{{ block.text }}
</span>
@@ -250,7 +250,7 @@ function shouldShowRaw(key: string) {
>
<span
v-if="block.op === 'removed'"
- class="max-w-full text-red-700 px-1 bg-red-50 rounded-md line-through decoration-clone !leading-[18px]"
+ class="max-w-full text-nc-content-red-dark px-1 bg-nc-bg-red-light rounded-md line-through decoration-clone !leading-[18px]"
:class="{
'whitespace-pre-wrap': meta[columnKey]?.type === 'LongText',
}"
@@ -259,7 +259,7 @@ function shouldShowRaw(key: string) {
</span>
<span
v-else-if="block.op === 'added'"
- class="max-w-full text-green-700 px-1 bg-green-50 rounded-md decoration-clone !leading-[18px]"
+ class="max-w-full text-nc-content-green-dark px-1 bg-nc-bg-green-light rounded-md decoration-clone !leading-[18px]"
:class="{
'whitespace-pre-wrap': meta[columnKey]?.type === 'LongText',
}"
@@ -283,12 +283,12 @@ function shouldShowRaw(key: string) {
<template v-for="(block, i) of safeJsonDiff(columnKey)" :key="i">
<pre
v-if="block.op === 'removed'"
- class="text-small1 text-red-700 border-1 border-red-200 rounded-md px-1 bg-red-50 line-through decoration-clone inline"
+ class="text-small1 text-nc-content-red-dark border-1 border-nc-red-200 rounded-md px-1 bg-nc-bg-red-light line-through decoration-clone inline"
>{{ block.text }}</pre
>
<pre
v-else-if="block.op === 'added'"
- class="text-small1 text-green-700 border-1 border-green-200 rounded-md px-1 bg-green-50 decoration-clone inline"
+ class="text-small1 text-nc-content-green-dark border-1 border-nc-green-200 rounded-md px-1 bg-nc-bg-green-light decoration-clone inline"
>{{ block.text }}</pre
>
<pre v-else class="inline text-small1">{{ block.text }}</pre>
@@ -298,7 +298,7 @@ function shouldShowRaw(key: string) {
<template v-else>
<div
v-if="isShowableValue(processOldDataFor(columnKey))"
- class="max-w-full nc-audit-mini-item-cell nc-audit-removal !text-red-700 border-1 border-red-200 rounded-md bg-red-50 line-through"
+ class="max-w-full nc-audit-mini-item-cell nc-audit-removal !text-nc-content-red-dark border-1 border-nc-red-200 rounded-md bg-nc-bg-red-light line-through"
:class="{
'px-1 py-0.25': shouldUseNormalizedPadding(columnKey),
'!p-0.25': shouldUseUniformPadding(columnKey),
@@ -317,12 +317,12 @@ function shouldShowRaw(key: string) {
:class="{
'min-w-[100px]': normalizeMeta(columnKey).is_progress,
}"
- class="!text-red-700"
+ class="!text-nc-content-red-dark"
/>
</div>
<div
v-if="isShowableValue(processNewDataFor(columnKey))"
- class="nc-audit-mini-item-cell nc-audit-addition border-1 border-green-200 rounded-md bg-green-50"
+ class="nc-audit-mini-item-cell nc-audit-addition border-1 border-nc-green-200 rounded-md bg-nc-bg-green-light"
:class="{
'px-1 py-0.25': shouldUseNormalizedPadding(columnKey),
'!p-0.25': shouldUseUniformPadding(columnKey),
@@ -341,7 +341,7 @@ function shouldShowRaw(key: string) {
:class="{
'min-w-[100px]': normalizeMeta(columnKey).is_progress,
}"
- class="!text-green-700"
+ class="!text-nc-content-green-dark"
/>
</div>
</template>
@@ -425,7 +425,7 @@ function shouldShowRaw(key: string) {
.nc-cell-field > div {
display: flex !important;
& > .ant-tag {
- @apply !m-0 !text-inherit !border-1 !border-gray-300 !pr-1 !pl-0.5 !bg-gray-100 !rounded-[17px];
+ @apply !m-0 !text-inherit !border-1 !border-nc-border-gray-dark !pr-1 !pl-0.5 !bg-nc-bg-gray-light !rounded-[17px];
& > span > div + div {
@apply flex items-center !text-small1 font-weight-500 !leading-[16px];
}
@@ -442,17 +442,17 @@ function shouldShowRaw(key: string) {
}
.nc-audit-mini-item-cell :deep(.nc-cell-user:has(.ant-tag + .ant-tag)) {
.ant-tag {
- @apply !border-1 !border-gray-300 !py-0.5 !px-1 !bg-gray-100 !rounded-[6px];
+ @apply !border-1 !border-nc-border-gray-dark !py-0.5 !px-1 !bg-nc-bg-gray-light !rounded-[6px];
}
}
.nc-audit-mini-item-cell.nc-audit-removal :deep(.nc-cell-user) {
.ant-tag > span > div + div {
- @apply !text-red-700;
+ @apply !text-nc-content-red-dark;
}
}
.nc-audit-mini-item-cell.nc-audit-addition :deep(.nc-cell-user) {
.ant-tag > span > div + div {
- @apply !text-green-700;
+ @apply !text-nc-content-green-dark;
}
}
</style>
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/Audits.vue b/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/Audits.vue
index 6edc2c00f6..5b752799d2 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/Audits.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/Audits.vue
@@ -113,25 +113,25 @@ function isV0Audit(audit: AuditType) {
<div v-else ref="auditsWrapperEl" class="flex flex-col h-full nc-scrollbar-thin pb-1">
<template v-if="consolidatedAudits.length === 0">
<div class="flex flex-col text-center justify-center h-full">
- <div class="text-center text-3xl text-gray-600">
+ <div class="text-center text-3xl text-nc-content-gray-subtle2">
<MdiHistory />
</div>
- <div class="font-bold text-center my-1 text-gray-600">See changes to this record</div>
- <div v-if="auditRetentionLimit" class="text-center text-gray-600">
+ <div class="font-bold text-center my-1 text-nc-content-gray-subtle2">See changes to this record</div>
+ <div v-if="auditRetentionLimit" class="text-center text-nc-content-gray-subtle2">
Your current plan provides <span class="font-bold">{{ auditRetentionLimit }}</span> of revision history.
</div>
</div>
</template>
<template v-else>
<div class="mt-auto" />
- <div v-if="auditRetentionLimit" class="text-center text-gray-600 my-2">
+ <div v-if="auditRetentionLimit" class="text-center text-nc-content-gray-subtle2 my-2">
You have <span class="font-bold">{{ auditRetentionLimit }}</span> of revision history.
</div>
<div v-if="hasMoreAudits" class="p-3 text-center">
<NcButton size="small" type="secondary" @click="initLoadMoreAudits()"> Load earlier </NcButton>
</div>
<div v-for="audit of consolidatedAudits" :key="audit.id" :class="`${audit.id}`" class="nc-audit-item">
- <div class="group gap-3 overflow-hidden px-3 py-2 transition hover:bg-gray-100">
+ <div class="group gap-3 overflow-hidden px-3 py-2 transition hover:bg-nc-bg-gray-light">
<div class="flex items-start justify-between">
<div class="flex items-start gap-3 flex-1 w-full">
<GeneralUserIcon
@@ -144,10 +144,10 @@ function isV0Audit(audit: AuditType) {
size="medium"
/>
<div class="flex h-[28px] items-center gap-2 w-[calc(100%_-_40px)]">
- <div class="truncate text-gray-800 font-medium !text-small !leading-[18px] overflow-hidden">
+ <div class="truncate text-nc-content-gray font-medium !text-small !leading-[18px] overflow-hidden">
{{ createdByAudit(audit) }}
</div>
- <div class="text-xs text-gray-500">
+ <div class="text-xs text-nc-content-gray-muted">
<NcTooltip>
<template #title>{{ parseStringDateTime(audit.created_at) }}</template>
{{ timeAgo(audit.created_at!) }}
@@ -160,16 +160,16 @@ function isV0Audit(audit: AuditType) {
<div
v-if="audit.details"
v-dompurify-html="audit.details"
- class="rounded-lg border-1 border-gray-200 bg-gray-50 divide-y py-2 px-3"
+ class="rounded-lg border-1 border-nc-border-gray-medium bg-nc-bg-gray-extralight divide-y py-2 px-3"
></div>
- <div v-else class="rounded-lg border-1 border-gray-200 bg-gray-50 divide-y py-2 px-3">
+ <div v-else class="rounded-lg border-1 border-nc-border-gray-medium bg-nc-bg-gray-extralight divide-y py-2 px-3">
{{ audit.description }}
</div>
</div>
<div v-else-if="audit?.op_type === 'DATA_INSERT'" class="pl-9">created the record.</div>
<div v-else-if="['DATA_LINK', 'DATA_UNLINK'].includes(audit?.op_type)" class="pl-9">
- <div class="rounded-lg border-1 border-gray-200 bg-gray-50 divide-y py-2 px-3">
- <div class="flex items-center gap-2 !text-gray-600 text-xs nc-audit-mini-item-header mb-3">
+ <div class="rounded-lg border-1 border-nc-border-gray-medium bg-nc-bg-gray-extralight divide-y py-2 px-3">
+ <div class="flex items-center gap-2 !text-nc-content-gray-subtle2 text-xs nc-audit-mini-item-header mb-3">
<SmartsheetHeaderVirtualCellIcon
:column-meta="{ uidt: 'Links', colOptions: { type: safeJsonParse(audit.details).type } }"
class="!m-0"
@@ -205,7 +205,7 @@ function isV0Audit(audit: AuditType) {
</div>
</div>
<template v-else-if="audit?.op_type === 'DATA_UPDATE'">
- <div class="ml-9 rounded-lg border-1 border-gray-200 bg-gray-50 divide-y">
+ <div class="ml-9 rounded-lg border-1 border-nc-border-gray-medium bg-nc-bg-gray-extralight divide-y">
<SmartsheetExpandedFormSidebarAuditMiniItem :audit="audit" />
</div>
</template>
@@ -218,7 +218,7 @@ function isV0Audit(audit: AuditType) {
<style scoped lang="scss">
:deep(.red.lighten-4) {
- @apply bg-red-100 rounded-md line-through;
+ @apply bg-nc-bg-red-dark rounded-md line-through;
}
.nc-audit-item {
@@ -226,20 +226,20 @@ function isV0Audit(audit: AuditType) {
}
:deep(.green.lighten-4) {
- @apply bg-green-100 rounded-md !mr-3;
+ @apply bg-nc-bg-green-dark rounded-md !mr-3;
}
.audit-link-container {
@apply flex flex-row flex-wrap gap-2;
.audit-link-addition {
@apply flex gap-2 flex-wrap;
span {
- @apply !text-[13px] px-1 py-0.5 text-green-700 font-weight-500 border-1 border-green-200 rounded-md bg-green-50 decoration-clone;
+ @apply !text-[13px] px-1 py-0.5 text-nc-content-green-dark font-weight-500 border-1 border-green-200 rounded-md bg-nc-bg-green-light decoration-clone;
}
}
.audit-link-removal {
@apply flex gap-2 flex-wrap;
span {
- @apply !text-[13px] px-1 py-0.5 text-red-700 font-weight-500 border-1 border-red-200 rounded-md bg-red-50 decoration-clone line-through;
+ @apply !text-[13px] px-1 py-0.5 text-nc-content-red-dark font-weight-500 border-1 border-red-200 rounded-md bg-nc-bg-red-light decoration-clone line-through;
}
}
}
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/Comments.vue b/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/Comments.vue
index aff7913aa8..1fe88f2b90 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/Comments.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/Comments.vue
@@ -299,10 +299,10 @@ onBeforeUnmount(() => {
</div>
<div v-else class="flex flex-col h-full">
<div v-if="comments.length === 0" class="flex flex-col my-1 text-center justify-center h-full nc-scrollbar-thin">
- <div class="text-center text-3xl text-gray-700">
+ <div class="text-center text-3xl text-nc-content-gray-subtle">
<GeneralIcon icon="commentHere" />
</div>
- <div class="font-medium text-center my-6 text-gray-500">
+ <div class="font-medium text-center my-6 text-nc-content-gray-muted">
{{ hasEditPermission ? $t('activity.startCommenting') : $t('activity.noCommentsYet') }}
</div>
</div>
@@ -321,9 +321,9 @@ onBeforeUnmount(() => {
>
<div
:class="{
- 'hover:bg-gray-100': editCommentValue?.id !== commentItem!.id,
- 'nc-hovered-comment bg-gray-100': hoveredCommentId === commentItem!.id
- }"
+ 'hover:bg-nc-bg-gray-light': editCommentValue?.id !== commentItem!.id,
+ 'nc-hovered-comment bg-nc-bg-gray-light': hoveredCommentId === commentItem!.id
+ }"
class="group gap-3 overflow-hidden px-3 py-2 transition-colors"
>
<div class="flex items-start justify-between">
@@ -349,15 +349,15 @@ onBeforeUnmount(() => {
/>
<div class="flex h-[28px] items-center gap-3 w-[calc(100%_-_40px)]">
<NcDropdown placement="topLeft" :trigger="['hover']" class="flex-none max-w-[calc(100%_-_72px)]">
- <div class="truncate text-gray-800 font-medium !text-small !leading-[18px] overflow-hidden">
+ <div class="truncate text-nc-content-gray font-medium !text-small !leading-[18px] overflow-hidden">
{{ createdBy(commentItem) }}
</div>
<template #overlay>
- <div class="bg-white rounded-lg">
+ <div class="bg-nc-bg-default rounded-lg">
<div class="flex items-center gap-4 py-3 px-2">
<GeneralUserIcon
- class="border-1 border-gray-200 rounded-full"
+ class="border-1 border-nc-border-gray-medium rounded-full"
:user="{
display_name: commentItem?.created_display_name,
email: commentItem?.created_by_email,
@@ -366,17 +366,17 @@ onBeforeUnmount(() => {
size="base"
/>
<div class="flex flex-col">
- <div class="font-semibold text-gray-800">
+ <div class="font-semibold text-nc-content-gray">
{{ createdBy(commentItem) }}
</div>
- <div class="text-xs text-gray-600">
+ <div class="text-xs text-nc-content-gray-subtle2">
{{ commentItem.created_by_email }}
</div>
</div>
</div>
<div
v-if="isUIAllowed('dataEdit')"
- class="px-3 rounded-b-lg !text-[13px] items-center text-gray-600 flex gap-1 bg-gray-100 py-1.5"
+ class="px-3 rounded-b-lg !text-[13px] items-center text-nc-content-gray-subtle2 flex gap-1 bg-nc-bg-gray-light py-1.5"
>
Has <RolesBadge size="sm" :border="false" :role="getUserRole(commentItem.created_by_email!)" />
role in base
@@ -384,7 +384,7 @@ onBeforeUnmount(() => {
</div>
</template>
</NcDropdown>
- <div class="text-xs text-gray-500">
+ <div class="text-xs text-nc-content-gray-muted">
{{ timeAgo(commentItem.created_at!) }}
</div>
</div>
@@ -397,7 +397,7 @@ onBeforeUnmount(() => {
placement="bottomRight"
>
<NcButton
- class="nc-expand-form-more-actions !hover:bg-gray-200 !w-7 !h-7 !bg-transparent"
+ class="nc-expand-form-more-actions !hover:bg-nc-bg-gray-medium !w-7 !h-7 !bg-transparent"
size="xsmall"
type="text"
>
@@ -425,7 +425,7 @@ onBeforeUnmount(() => {
<NcDivider />
<NcMenuItem
v-e="['c:row-expand:comment:delete']"
- class="!text-red-500 !hover:bg-red-50"
+ class="!text-nc-content-red-medium !hover:bg-nc-bg-red-light"
@click="deleteComment(commentItem.id!)"
>
<div class="flex gap-2 items-center">
@@ -440,7 +440,7 @@ onBeforeUnmount(() => {
<div v-if="appInfo.ee">
<NcTooltip v-if="!commentItem.resolved_by && hasEditPermission">
<NcButton
- class="nc-resolve-comment-btn !w-7 !h-7 !bg-transparent !hover:bg-gray-200 !hidden !group-hover:block"
+ class="nc-resolve-comment-btn !w-7 !h-7 !bg-transparent !hover:bg-nc-bg-gray-medium !hidden !group-hover:block"
size="xsmall"
type="text"
@click="resolveComment(commentItem.id!)"
@@ -454,12 +454,12 @@ onBeforeUnmount(() => {
<NcTooltip v-else-if="commentItem.resolved_by">
<template #title>{{ `${$t('activity.resolvedBy')} ${commentItem.resolved_display_name}` }}</template>
<NcButton
- class="!h-7 !w-7 !bg-transparent !hover:bg-gray-200 text-semibold"
+ class="!h-7 !w-7 !bg-transparent !hover:bg-nc-bg-gray-medium text-semibold"
size="xsmall"
type="text"
@click="resolveComment(commentItem.id!)"
>
- <GeneralIcon class="text-md rounded-full bg-[#17803D] text-white" icon="checkFill" />
+ <GeneralIcon class="text-md rounded-full bg-nc-fill-green-dark text-white" icon="checkFill" />
</NcButton>
</NcTooltip>
</div>
@@ -477,7 +477,7 @@ onBeforeUnmount(() => {
autofocus
autofocus-to-end
:hide-options="false"
- class="expanded-form-comment-edit-input cursor-text expanded-form-comment-input !py-2 !px-2 !m-0 w-full !border-1 !border-gray-200 !rounded-lg !bg-white !text-gray-800 !text-small !leading-18px !max-h-[240px]"
+ class="expanded-form-comment-edit-input cursor-text expanded-form-comment-input !py-2 !px-2 !m-0 w-full !border-1 !border-nc-border-gray-medium !rounded-lg !bg-nc-bg-default !text-nc-content-gray !text-small !leading-18px !max-h-[240px]"
data-testid="expanded-form-comment-input"
@save="onEditComment"
@keydown.esc="onCancel"
@@ -493,7 +493,7 @@ onBeforeUnmount(() => {
<div v-else class="space-y-1 pl-9">
<div
- class="nc-rich-text-content !text-small !leading-18px !text-gray-800"
+ class="nc-rich-text-content !text-small !leading-18px !text-nc-content-gray"
v-html="parsedHtmlComments[commentItem.id]"
></div>
</div>
@@ -507,7 +507,7 @@ onBeforeUnmount(() => {
v-model:value="comment"
:hide-options="false"
:placeholder="`${$t('general.comment')}...`"
- class="expanded-form-comment-input !py-2 !px-2 cursor-text border-1 rounded-lg w-full bg-transparent !text-gray-800 !text-small !leading-18px !max-h-[240px]"
+ class="expanded-form-comment-input !py-2 !px-2 cursor-text border-1 rounded-lg w-full bg-transparent !text-nc-content-gray !text-small !leading-18px !max-h-[240px]"
:autofocus="isExpandedFormCommentMode"
data-testid="expanded-form-comment-input"
@focus="isExpandedFormCommentMode = false"
@@ -526,7 +526,7 @@ onBeforeUnmount(() => {
box-shadow: none;
&:focus,
&:focus-within {
- @apply min-h-16 !bg-white border-brand-500;
+ @apply min-h-16 !bg-nc-bg-default border-nc-border-brand;
box-shadow: 0px 0px 0px 2px rgba(51, 102, 255, 0.24);
}
&::placeholder {
@@ -535,7 +535,7 @@ onBeforeUnmount(() => {
}
:deep(.expanded-form-comment-edit-input .nc-comment-rich-editor) {
- @apply bg-white;
+ @apply bg-nc-bg-default;
}
.nc-hovered-comment {
@@ -546,7 +546,7 @@ onBeforeUnmount(() => {
}
:deep(.nc-rich-link-tooltip) {
- @apply text-gray-500;
+ @apply text-nc-content-gray-muted;
}
.nc-rich-text-content {
@@ -558,6 +558,6 @@ onBeforeUnmount(() => {
<style lang="scss">
.nc-rich-link-tooltip-popup {
- @apply text-xs bg-gray-800 text-white px-2 py-1 rounded-lg;
+ @apply text-xs bg-nc-content-gray text-nc-content-inverted-primary px-2 py-1 rounded-lg;
}
</style>
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/index.vue b/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/index.vue
index 69320300e6..691b8a12b5 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/index.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/Sidebar/index.vue
@@ -17,7 +17,7 @@ watch(tab, (newValue) => {
</script>
<template>
- <div class="flex flex-col bg-white !h-full w-full rounded-br-2xl overflow-hidden">
+ <div class="flex flex-col bg-nc-bg-default !h-full w-full rounded-br-2xl overflow-hidden">
<NcTabs v-model:active-key="tab" class="h-full">
<a-tab-pane v-if="props.showFieldsTab" key="fields" class="w-full h-full">
<template #tab>
@@ -71,7 +71,7 @@ watch(tab, (newValue) => {
:deep(.ant-tabs) {
@apply !overflow-visible;
.ant-tabs-nav {
- @apply px-3 bg-white;
+ @apply px-3 bg-nc-bg-default;
.ant-tabs-nav-list {
@apply w-[99%] mx-auto gap-6;
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/ViewModeSelector.vue b/packages/nc-gui/components/smartsheet/expanded-form/ViewModeSelector.vue
index 86647e69e2..b371e4a1a7 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/ViewModeSelector.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/ViewModeSelector.vue
@@ -60,7 +60,7 @@ onMounted(() => {
<template>
<div
v-if="isViewModeEnabled"
- class="tab-wrapper flex flex-row rounded-lg border-1 border-nc-border-gray-medium bg-white h-7 overflow-hidden"
+ class="tab-wrapper flex flex-row rounded-lg border-1 border-nc-border-gray-medium bg-nc-bg-default h-7 overflow-hidden"
>
<NcTooltip v-for="(item, idx) of items" :key="item.value" :disabled="!item.tooltip">
<template #title>{{ item.tooltip }}</template>
@@ -88,7 +88,7 @@ onMounted(() => {
<style lang="scss" scoped>
.tab {
- @apply flex flex-row items-center h-full justify-center px-2 border-1 border-t-0 border-b-0 border-nc-border-gray-medium text-gray-600 hover:text-black cursor-pointer transition-all duration-300 select-none;
+ @apply flex flex-row items-center h-full justify-center px-2 border-1 border-t-0 border-b-0 border-nc-border-gray-medium text-nc-content-gray-subtle2 hover:text-nc-content-gray-extreme cursor-pointer transition-all duration-300 select-none;
&.first-tab {
@apply border-0;
@@ -119,7 +119,7 @@ onMounted(() => {
}
.active {
- @apply bg-nc-bg-brand text-brand-600 hover:text-brand-600;
+ @apply bg-nc-bg-brand text-nc-content-brand-disabled hover:text-nc-content-brand-disabled;
box-shadow: 0px 3px 1px -2px rgba(0, 0, 0, 0.06), 0px 5px 3px -2px rgba(0, 0, 0, 0.02);
}
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/index.vue b/packages/nc-gui/components/smartsheet/expanded-form/index.vue
index 92bb050fe0..82aa21aedf 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/index.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/index.vue
@@ -689,11 +689,11 @@ export default {
<div class="h-[85vh] xs:(max-h-full h-full) max-h-215 flex flex-col">
<div v-if="isMobileMode" class="flex-none h-4 flex items-center justify-center">
<div class="flex-none h-full flex items-center justify-center cursor-pointer" @click="onClose">
- <div class="w-[72px] h-[2px] rounded-full bg-[#49494a]"></div>
+ <div class="w-[72px] h-[2px] rounded-full bg-nc-bg-gray-dark"></div>
</div>
</div>
<div
- class="flex gap-2 min-h-7 flex-shrink-0 w-full items-center nc-expanded-form-header p-4 xs:(px-2 py-0 min-h-[48px]) border-b-1 border-gray-200"
+ class="flex gap-2 min-h-7 flex-shrink-0 w-full items-center nc-expanded-form-header p-4 xs:(px-2 py-0 min-h-[48px]) border-b-1 border-nc-border-gray-medium"
>
<div class="flex gap-2 min-w-0 min-h-8">
<div class="flex gap-2">
@@ -701,7 +701,7 @@ export default {
<template #title> {{ $t('labels.prevRow') }} {{ renderAltOrOptlKey() }} + ←</template>
<NcButton
:disabled="isFirstRow || isLoading"
- class="nc-prev-arrow !w-7 !h-7 !text-gray-500 !disabled:text-gray-300"
+ class="nc-prev-arrow !w-7 !h-7 !text-nc-content-gray-muted !disabled:text-nc-content-brand-hover"
type="text"
size="xsmall"
@click="onPrev"
@@ -713,7 +713,7 @@ export default {
<template #title> {{ $t('labels.nextRow') }} {{ renderAltOrOptlKey() }} + β†’</template>
<NcButton
:disabled="isLastRow || isLoading"
- class="nc-next-arrow !w-7 !h-7 !text-gray-500 !disabled:text-gray-300"
+ class="nc-next-arrow !w-7 !h-7 !text-nc-content-gray-muted !disabled:text-nc-content-brand-hover"
type="text"
size="xsmall"
@click="onNext"
@@ -726,21 +726,21 @@ export default {
<a-skeleton-input active class="!h-6 !sm:mr-14 !w-52 !rounded-md !overflow-hidden" size="small" />
</div>
<div v-else class="flex-1 flex items-center gap-2 xs:(flex-row-reverse justify-end) min-w-0">
- <div v-if="!props.showNextPrevIcons" class="hidden md:flex items-center rounded-lg bg-gray-100 px-2 py-1 gap-2">
- <GeneralIcon icon="table" class="text-gray-700 flex-none" />
+ <div v-if="!props.showNextPrevIcons" class="hidden md:flex items-center rounded-lg bg-nc-bg-gray-light px-2 py-1 gap-2">
+ <GeneralIcon icon="table" class="text-nc-content-inverted-secondary flex-none" />
<span class="nc-expanded-form-table-name whitespace-nowrap">
{{ tableTitle }}
</span>
</div>
<div
v-if="row.rowMeta?.new || props.newRecordHeader"
- class="flex items-center truncate font-bold text-gray-800 text-xl overflow-hidden"
+ class="flex items-center truncate font-bold text-nc-content-gray text-xl overflow-hidden"
>
{{ props.newRecordHeader ?? $t('activity.newRecord') }}
</div>
<div
v-else-if="displayValue && !row?.rowMeta?.new"
- class="flex items-center font-bold text-gray-800 text-2xl overflow-hidden"
+ class="flex items-center font-bold text-nc-content-gray text-2xl overflow-hidden"
>
<span class="min-w-[120px] md:min-w-[300px]">
<LazySmartsheetPlainCell v-model="displayValue" :column="displayField" show-tooltip />
@@ -781,7 +781,7 @@ export default {
<NcButton
v-if="!isNew && rowId && !isMobileMode"
:disabled="isLoading"
- class="!<lg:hidden text-gray-700 !h-7 !w-7"
+ class="!<lg:hidden text-nc-content-inverted-secondary !h-7 !w-7"
type="text"
size="xsmall"
@click="copyRecordUrl()"
@@ -800,7 +800,7 @@ export default {
</NcTooltip>
<NcDropdown v-if="!isNew && rowId && !isMobileMode" placement="bottomRight">
<NcButton type="text" size="xsmall" class="nc-expand-form-more-actions !w-7 !h-7" :disabled="isLoading">
- <GeneralIcon icon="threeDotVertical" class="text-md" :class="isLoading ? 'text-gray-300' : 'text-gray-700'" />
+ <GeneralIcon icon="threeDotVertical" class="text-md" :class="isLoading ? 'text-nc-content-brand-hover' : 'text-nc-content-inverted-secondary'" />
</NcButton>
<template #overlay>
<NcMenu variant="small">
@@ -861,7 +861,7 @@ export default {
<template #default="{ isAllowed }">
<NcMenuItem
:class="{
- '!text-red-500 !hover:bg-red-50': isAllowed,
+ '!text-nc-content-red-medium !hover:bg-nc-bg-red-light': isAllowed,
}"
:disabled="!isAllowed"
@click="!isNew && onDeleteRowClick()"
@@ -890,7 +890,7 @@ export default {
size="xsmall"
@click="onClose"
>
- <GeneralIcon class="text-md text-gray-700 h-4 w-4" icon="close" />
+ <GeneralIcon class="text-md text-nc-content-inverted-secondary h-4 w-4" icon="close" />
</NcButton>
</div>
</div>
@@ -942,7 +942,7 @@ export default {
<GeneralDeleteModal v-model:visible="showDeleteRowModal" entity-name="Record" :on-delete="onConfirmDeleteRowClick">
<template #entity-preview>
<span>
- <div class="flex flex-row items-center py-2.25 px-2.5 bg-gray-50 rounded-lg text-gray-700">
+ <div class="flex flex-row items-center py-2.25 px-2.5 bg-nc-bg-gray-extralight rounded-lg text-nc-content-inverted-secondary">
<div class="text-ellipsis overflow-hidden select-none w-full pl-1.75 break-keep whitespace-nowrap">
<LazySmartsheetPlainCell v-model="displayValue" :column="displayField" />
</div>
@@ -984,7 +984,7 @@ export default {
}
.nc-expanded-cell-header {
- @apply w-full text-gray-500 !font-weight-500 !text-sm xs:(text-gray-600 mb-2 !text-small) pr-3;
+ @apply w-full text-nc-content-gray-muted !font-weight-500 !text-sm xs:(text-nc-content-gray-subtle2 mb-2 !text-small) pr-3;
svg.nc-cell-icon,
svg.nc-virtual-cell-icon {
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/AuditInfoExpressive.vue b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/AuditInfoExpressive.vue
index f7f2555693..6cbb397d54 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/AuditInfoExpressive.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/AuditInfoExpressive.vue
@@ -113,7 +113,7 @@ function isShowableValue(value: any) {
<div v-for="columnKey in columnKeys" :key="columnKey" class="relative not-last:mb-4">
<GeneralIcon
icon="ncNode"
- class="w-[16px] h-[16px] text-gray-500 bg-white absolute left-0 transform -translate-x-1/2"
+ class="w-[16px] h-[16px] text-nc-content-gray-muted bg-nc-bg-default absolute left-0 transform -translate-x-1/2"
:class="[
['JSON', 'Attachment', 'SingleLineText', 'LongText'].includes(meta[columnKey]?.type)
? 'top-1'
@@ -122,7 +122,7 @@ function isShowableValue(value: any) {
/>
<div class="ml-6.5">
<div class="text-small1 font-weight-500 inline-flex items-center flex-wrap gap-1 w-full max-w-full">
- <span class="text-gray-600 text-xs"> changed </span>
+ <span class="text-nc-content-gray-subtle2 text-xs"> changed </span>
<span
class="rounded-md px-1 !h-[20px] inline-flex items-center gap-1 text-nc-content-gray-emphasis border-1 border-nc-border-gray-medium"
>
@@ -143,11 +143,13 @@ function isShowableValue(value: any) {
</span>
<template v-if="meta[columnKey]?.type === 'Attachment'">
<div v-if="processOldDataFor(columnKey)?.length > 0" class="w-full">
- <div class="border-1 border-red-200 rounded-md bg-red-50 p-0.5 flex flex-col items-start gap-0.5 w-[284px]">
+ <div
+ class="border-1 border-nc-red-200 rounded-md bg-nc-bg-red-light p-0.5 flex flex-col items-start gap-0.5 w-[284px]"
+ >
<div
v-for="(item, i) of processOldDataFor(columnKey)"
:key="item.url || item.title"
- class="border-1 border-gray-200 rounded-md bg-white w-full"
+ class="border-1 border-nc-border-gray-medium rounded-md bg-nc-bg-default w-full"
>
<div class="flex items-center gap-2 w-full">
<div class="flex items-center justify-center w-8 aspect-square">
@@ -161,10 +163,10 @@ function isShowableValue(value: any) {
<CellAttachmentIconView :item="item" class="!w-8 !h-8" />
</div>
</div>
- <span class="w-0 flex-1 truncate text-small1 font-weight-500 text-gray-600">
+ <span class="w-0 flex-1 truncate text-small1 font-weight-500 text-nc-content-gray-subtle2">
{{ item.title }}
</span>
- <span class="text-xs font-weight-500 p-2 text-gray-500">
+ <span class="text-xs font-weight-500 p-2 text-nc-content-gray-muted">
{{ getReadableFileSize(item.size) }}
</span>
</div>
@@ -172,11 +174,13 @@ function isShowableValue(value: any) {
</div>
</div>
<div v-if="processNewDataFor(columnKey)?.length > 0" class="w-full">
- <div class="border-1 border-green-200 rounded-md bg-green-50 p-0.5 flex flex-col items-start gap-0.5 w-[284px]">
+ <div
+ class="border-1 border-nc-green-200 rounded-md bg-nc-bg-green-light p-0.5 flex flex-col items-start gap-0.5 w-[284px]"
+ >
<div
v-for="(item, i) of processNewDataFor(columnKey)"
:key="item.url || item.title"
- class="border-1 border-gray-200 rounded-md bg-white w-full"
+ class="border-1 border-nc-border-gray-medium rounded-md bg-nc-bg-default w-full"
>
<div class="flex items-center gap-2 w-full">
<div class="flex items-center justify-center w-8 aspect-square">
@@ -190,10 +194,10 @@ function isShowableValue(value: any) {
<CellAttachmentIconView :item="item" class="!w-8 !h-8" />
</div>
</div>
- <span class="w-0 flex-1 truncate text-small1 font-weight-500 text-gray-600">
+ <span class="w-0 flex-1 truncate text-small1 font-weight-500 text-nc-content-gray-subtle2">
{{ item.title }}
</span>
- <span class="text-xs font-weight-500 p-2 text-gray-500">
+ <span class="text-xs font-weight-500 p-2 text-nc-content-gray-muted">
{{ getReadableFileSize(item.size) }}
</span>
</div>
@@ -205,13 +209,13 @@ function isShowableValue(value: any) {
<template v-for="(block, i) of diffTextBlocks(oldData[columnKey] || '', newData[columnKey] || '')" :key="i">
<span
v-if="block.op === 'removed'"
- class="max-w-full text-red-700 border-1 border-red-200 rounded-md px-1 bg-red-50 line-through decoration-clone !leading-[18px]"
+ class="max-w-full text-nc-content-red-dark border-1 border-nc-red-200 rounded-md px-1 bg-nc-bg-red-light line-through decoration-clone !leading-[18px]"
>
{{ block.text }}
</span>
<span
v-else-if="block.op === 'added'"
- class="max-w-full text-green-700 border-1 border-green-200 rounded-md px-1 bg-green-50 decoration-clone !leading-[18px]"
+ class="max-w-full text-nc-content-green-dark border-1 border-nc-green-200 rounded-md px-1 bg-nc-bg-green-light decoration-clone !leading-[18px]"
>
{{ block.text }}
</span>
@@ -235,7 +239,7 @@ function isShowableValue(value: any) {
>
<span
v-if="block.op === 'removed'"
- class="max-w-full text-red-700 px-1 bg-red-50 rounded-md line-through decoration-clone !leading-[18px]"
+ class="max-w-full text-nc-content-red-dark px-1 bg-nc-bg-red-light rounded-md line-through decoration-clone !leading-[18px]"
:class="{
'whitespace-pre-wrap': meta[columnKey]?.type === 'LongText',
}"
@@ -244,7 +248,7 @@ function isShowableValue(value: any) {
</span>
<span
v-else-if="block.op === 'added'"
- class="max-w-full text-green-700 px-1 bg-green-50 rounded-md decoration-clone !leading-[18px]"
+ class="max-w-full text-nc-content-green-dark px-1 bg-nc-bg-green-light rounded-md decoration-clone !leading-[18px]"
:class="{
'whitespace-pre-wrap': meta[columnKey]?.type === 'LongText',
}"
@@ -267,14 +271,14 @@ function isShowableValue(value: any) {
<div class="w-full flex justify-start">
<pre
v-if="isShowableValue(processOldDataFor(columnKey))"
- class="!text-red-700 border-1 border-red-200 rounded-md bg-red-50 line-through !mb-0 mt-1 p-1 max-w-full nc-scrollbar-thin"
+ class="!text-nc-content-red-dark border-1 border-nc-red-200 rounded-md bg-nc-bg-red-light line-through !mb-0 mt-1 p-1 max-w-full nc-scrollbar-thin"
>{{ processOldDataFor(columnKey) }}</pre
>
</div>
<div class="w-full flex justify-start">
<pre
v-if="isShowableValue(processNewDataFor(columnKey))"
- class="!text-green-700 border-1 border-green-200 rounded-md bg-green-50 !mb-0 mt-1 p-1 max-w-full nc-scrollbar-thin"
+ class="!text-nc-content-green-dark border-1 border-nc-green-200 rounded-md bg-nc-bg-green-light !mb-0 mt-1 p-1 max-w-full nc-scrollbar-thin"
>{{ processNewDataFor(columnKey) }}</pre
>
</div>
@@ -283,7 +287,7 @@ function isShowableValue(value: any) {
<div
v-if="isShowableValue(processOldDataFor(columnKey))"
:data-label="processOldDataFor(columnKey)"
- class="max-w-full nc-expressive-mini-item-cell nc-audit-removal !text-red-700 border-1 border-red-200 rounded-md bg-red-50 line-through"
+ class="max-w-full nc-expressive-mini-item-cell nc-audit-removal !text-nc-content-red-dark border-1 border-nc-red-200 rounded-md bg-nc-bg-red-light line-through"
:class="{
'px-1 py-0': shouldUseNormalizedPadding(columnKey),
'!px-0.25 !py-0.25': shouldUseUniformPadding(columnKey),
@@ -299,7 +303,7 @@ function isShowableValue(value: any) {
:model-value="processOldDataFor(columnKey)"
:edit-enabled="false"
:read-only="true"
- class="!text-red-700"
+ class="!text-nc-content-red-dark"
:class="{
'min-w-[100px]': normalizeMeta(columnKey).is_progress,
}"
@@ -308,7 +312,7 @@ function isShowableValue(value: any) {
<div
v-if="isShowableValue(processNewDataFor(columnKey))"
:data-label="processNewDataFor(columnKey)"
- class="max-w-full nc-expressive-mini-item-cell nc-audit-addition border-1 border-green-200 rounded-md bg-green-50"
+ class="max-w-full nc-expressive-mini-item-cell nc-audit-addition border-1 border-nc-green-200 rounded-md bg-nc-bg-green-light"
:class="{
'px-1 py-0': shouldUseNormalizedPadding(columnKey),
'!px-0.25 !py-0.25': shouldUseUniformPadding(columnKey),
@@ -324,7 +328,7 @@ function isShowableValue(value: any) {
:model-value="processNewDataFor(columnKey)"
:edit-enabled="false"
:read-only="true"
- class="!text-green-700"
+ class="!text-nc-content-green-dark"
:class="{
'min-w-[100px]': normalizeMeta(columnKey).is_progress,
}"
@@ -412,7 +416,7 @@ function isShowableValue(value: any) {
.nc-cell-field > div {
display: flex !important;
& > .ant-tag {
- @apply !m-0 !text-inherit !border-1 !border-gray-300 !pr-1 !pl-0.5 !bg-gray-100 !rounded-[17px];
+ @apply !m-0 !text-inherit !border-1 !border-nc-border-gray-dark !pr-1 !pl-0.5 !bg-nc-bg-gray-light !rounded-[17px];
& > span > div + div {
@apply flex items-center !text-small1 font-weight-500 !leading-[16px];
}
@@ -429,12 +433,12 @@ function isShowableValue(value: any) {
}
.nc-expressive-mini-item-cell.nc-audit-removal :deep(.nc-cell-user) {
.ant-tag > span > div + div {
- @apply !text-red-700;
+ @apply !text-nc-content-red-dark;
}
}
.nc-expressive-mini-item-cell.nc-audit-addition :deep(.nc-cell-user) {
.ant-tag > span > div + div {
- @apply !text-green-700;
+ @apply !text-nc-content-green-dark;
}
}
</style>
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/EntryAudit.vue b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/EntryAudit.vue
index 3af86c4410..d1c3726bcb 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/EntryAudit.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/EntryAudit.vue
@@ -43,12 +43,12 @@ const createdBy = computed(() => {
</script>
<template>
- <div class="py-4 ml-15.8 border-l border-gray-300">
+ <div class="py-4 ml-15.8 border-l border-nc-border-gray-dark">
<div class="flex items-center h-[32px] gap-2 mb-2">
<div
- class="w-[28px] h-[28px] bg-white flex items-center justify-center bg-white rounded-full border border-1 !border-gray-200 shadow-sm -ml-3.5"
+ class="w-[28px] h-[28px] bg-nc-bg-default flex items-center justify-center bg-nc-bg-default rounded-full border border-1 !border-nc-border-gray-medium shadow-sm -ml-3.5"
>
- <GeneralIcon icon="ncPenLine" class="w-[16px] h-[16px] text-gray-500" />
+ <GeneralIcon icon="ncPenLine" class="w-[16px] h-[16px] text-nc-content-gray-muted" />
</div>
<GeneralUserIcon
:user="{
@@ -62,17 +62,17 @@ const createdBy = computed(() => {
<span class="font-weight-700">
{{ createdBy }}
</span>
- <span v-if="props.auditGroup.audit?.op_type === 'DATA_INSERT'" class="font-weight-500 text-gray-600">
+ <span v-if="props.auditGroup.audit?.op_type === 'DATA_INSERT'" class="font-weight-500 text-nc-content-gray-subtle2">
created a record.
</span>
- <span v-else-if="props.auditGroup.audit?.op_type === 'DATA_UPDATE'" class="font-weight-500 text-gray-600">
+ <span v-else-if="props.auditGroup.audit?.op_type === 'DATA_UPDATE'" class="font-weight-500 text-nc-content-gray-subtle2">
updated {{ fieldsChanged }} fields
</span>
- <span v-else-if="props.auditGroup.audit?.op_type === 'DATA_LINK'" class="font-weight-500 text-gray-600">
+ <span v-else-if="props.auditGroup.audit?.op_type === 'DATA_LINK'" class="font-weight-500 text-nc-content-gray-subtle2">
updated 1 field
</span>
</p>
- <div class="text-xs font-weight-500 text-gray-500">
+ <div class="text-xs font-weight-500 text-nc-content-gray-muted">
<NcTooltip>
<template #title>{{ parseStringDateTime(props.auditGroup.audit?.created_at) }}</template>
{{ timeAgo(props.auditGroup.audit?.created_at) }}
@@ -83,7 +83,7 @@ const createdBy = computed(() => {
<div class="relative mb-2">
<GeneralIcon
icon="ncNode"
- class="w-[16px] h-[16px] text-gray-500 bg-white absolute top-1/2 left-0 transform -translate-y-1/2 -translate-x-1/2"
+ class="w-[16px] h-[16px] text-nc-content-gray-muted bg-nc-bg-default absolute top-1/2 left-0 transform -translate-y-1/2 -translate-x-1/2"
/>
<p class="text-sm font-weight-500 mb-1 ml-6.5">Record was created.</p>
</div>
@@ -95,10 +95,10 @@ const createdBy = computed(() => {
<div class="relative mb-2">
<GeneralIcon
icon="ncNode"
- class="w-[16px] h-[16px] text-gray-500 bg-white absolute top-1/2 left-0 transform -translate-y-1/2 -translate-x-1/2"
+ class="w-[16px] h-[16px] text-nc-content-gray-muted bg-nc-bg-default absolute top-1/2 left-0 transform -translate-y-1/2 -translate-x-1/2"
/>
<div class="text-sm ml-6.5 inline-flex items-center flex-wrap gap-1">
- <span class="text-small1 text-gray-600 font-weight-500"> changed </span>
+ <span class="text-small1 text-nc-content-gray-subtle2 font-weight-500"> changed </span>
<span
class="rounded-md px-1 !h-[20px] inline-flex items-center gap-1 text-nc-content-gray-emphasis border-1 border-nc-border-gray-medium"
>
@@ -115,12 +115,12 @@ const createdBy = computed(() => {
class="flex gap-1 flex-wrap"
>
<span
- class="!text-small p-0.5 font-weight-500 border-1 border-red-200 rounded-md bg-red-50 inline-flex items-center gap-1"
+ class="!text-small p-0.5 font-weight-500 border-1 border-nc-red-200 rounded-md bg-nc-bg-red-light inline-flex items-center gap-1"
>
<span
v-for="entry of safeGetFromAuditDetails(props.auditGroup.audit, 'consolidated_ref_display_values_unlinks')"
:key="entry.refRowId"
- class="text-brand-500 font-weight-500 line-through px-1 bg-[#F0F3FF] !rounded-md"
+ class="text-nc-content-brand font-weight-500 line-through px-1 bg-nc-bg-brand !rounded-md"
>
{{ entry.value }}
</span>
@@ -131,12 +131,12 @@ const createdBy = computed(() => {
class="flex gap-1 flex-wrap"
>
<span
- class="!text-small1 p-0.5 font-weight-500 border-1 border-green-200 rounded-md bg-green-50 inline-flex items-center gap-1"
+ class="!text-small1 p-0.5 font-weight-500 border-1 border-nc-green-200 rounded-md bg-nc-bg-green-light inline-flex items-center gap-1"
>
<span
v-for="entry of safeGetFromAuditDetails(props.auditGroup.audit, 'consolidated_ref_display_values_links')"
:key="entry.refRowId"
- class="text-brand-500 font-weight-500 px-1 bg-[#F0F3FF] !rounded-md"
+ class="text-nc-content-brand font-weight-500 px-1 bg-nc-bg-brand !rounded-md"
>
{{ entry.value }}
</span>
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/EntryComment.vue b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/EntryComment.vue
index 7559fcb8be..e5ae7f9019 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/EntryComment.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/EntryComment.vue
@@ -142,23 +142,23 @@ async function copyComment(comment: CommentType) {
/>
</div>
<div
- class="flex-1 bg-white rounded-lg border-1 group ml-11.5"
+ class="flex-1 bg-nc-bg-default rounded-lg border-1 group ml-11.5"
:class="{
- 'border-brand-200': isCreatedByYou,
- 'border-gray-200': !isCreatedByYou,
+ 'border-nc-brand-200': isCreatedByYou,
+ 'border-nc-border-gray-medium': !isCreatedByYou,
}"
>
<div
class="flex items-center gap-2 bg-nc-bg-gray-extralight px-4 py-1 border-b rounded-t-lg text-nc-content-gray min-h-[37px]"
:class="{
- '!bg-[#F0F3FF] border-brand-200': isCreatedByYou,
- 'border-gray-200': !isCreatedByYou,
+ '!bg-nc-bg-brand border-nc-brand-200': isCreatedByYou,
+ 'border-nc-border-gray-medium': !isCreatedByYou,
}"
>
- <span class="font-medium text-sm" :class="{ 'text-brand-600': isCreatedByYou }">
+ <span class="font-medium text-sm" :class="{ 'text-nc-content-brand-disabled': isCreatedByYou }">
{{ createdBy(props.comment) }}
</span>
- <span class="text-xs text-gray-500">
+ <span class="text-xs text-nc-content-gray-muted">
<NcTooltip>
<template #title>{{ parseStringDateTime(props.comment.created_at) }}</template>
{{ timeAgo(props.comment.created_at) }}
@@ -173,7 +173,7 @@ async function copyComment(comment: CommentType) {
class="opacity-0 transition !duration-150 pointer-events-none group-hover:opacity-100 group-hover:pointer-events-auto"
>
<NcButton
- class="!w-7 !h-7 !bg-transparent !hover:bg-gray-200"
+ class="!w-7 !h-7 !bg-transparent !hover:bg-nc-bg-gray-medium"
size="xsmall"
type="text"
@click="editComment(props.comment)"
@@ -189,7 +189,7 @@ async function copyComment(comment: CommentType) {
overlay-class-name="!min-w-[160px]"
placement="bottomRight"
>
- <NcButton class="!w-7 !h-7 !bg-transparent !hover:bg-gray-200" size="xsmall" type="text">
+ <NcButton class="!w-7 !h-7 !bg-transparent !hover:bg-nc-bg-gray-medium" size="xsmall" type="text">
<GeneralIcon class="text-md" icon="threeDotVertical" />
</NcButton>
<template #overlay>
@@ -202,11 +202,7 @@ async function copyComment(comment: CommentType) {
</NcMenuItem>
<template v-if="user && props.comment.created_by_email === user.email && hasEditPermission">
<NcDivider />
- <NcMenuItem
- v-e="['c:row-expand:comment:delete']"
- class="!text-red-500 !hover:bg-red-50"
- @click="deleteComment(props.comment.id!)"
- >
+ <NcMenuItem v-e="['c:row-expand:comment:delete']" danger @click="deleteComment(props.comment.id!)">
<div class="flex gap-2 items-center">
<component :is="iconMap.delete" class="cursor-pointer" />
{{ $t('general.delete') }}
@@ -222,7 +218,7 @@ async function copyComment(comment: CommentType) {
class="opacity-0 transition !duration-150 pointer-events-none group-hover:opacity-100 group-hover:pointer-events-auto"
>
<NcButton
- class="!w-7 !h-7 !bg-transparent !hover:bg-gray-200"
+ class="!w-7 !h-7 !bg-transparent !hover:bg-nc-bg-gray-medium"
size="xsmall"
type="text"
@click="resolveComment(props.comment.id)"
@@ -234,12 +230,12 @@ async function copyComment(comment: CommentType) {
<NcTooltip v-else-if="props.comment.resolved_by">
<template #title>{{ `Resolved by ${props.comment.resolved_display_name}` }}</template>
<NcButton
- class="!h-7 !w-7 !bg-transparent !hover:bg-gray-200 text-semibold"
+ class="!h-7 !w-7 !bg-transparent !hover:bg-nc-bg-gray-medium text-semibold"
size="xsmall"
type="text"
@click="resolveComment(props.comment.id!)"
>
- <GeneralIcon class="text-md rounded-full bg-[#17803D] text-white" icon="checkFill" />
+ <GeneralIcon class="text-md rounded-full bg-nc-fill-green-dark text-white" icon="checkFill" />
</NcButton>
</NcTooltip>
</div>
@@ -250,7 +246,7 @@ async function copyComment(comment: CommentType) {
autofocus
autofocus-to-end
:hide-options="false"
- class="cursor-text expanded-form-comment-input !py-3 !px-4 !pr-3 !m-0 w-full !border-1 !border-gray-200 !rounded-lg !bg-white !text-gray-800 !text-small !leading-18px !max-h-[240px]"
+ class="cursor-text expanded-form-comment-input !py-3 !px-4 !pr-3 !m-0 w-full !border-1 !border-nc-border-gray-medium !rounded-lg !bg-nc-bg-default !text-nc-content-gray !text-small !leading-18px !max-h-[240px]"
data-testid="expanded-form-comment-input"
sync-value-change
@save="onEditComment"
@@ -261,7 +257,7 @@ async function copyComment(comment: CommentType) {
<SmartsheetExpandedFormRichComment
v-else
:value="`${props.comment.comment} ${editedAt(props.comment)}`"
- class="!text-small !leading-18px !text-gray-800 px-4 py-3"
+ class="!text-small !leading-18px !text-nc-content-gray px-4 py-3"
read-only
sync-value-change
/>
@@ -273,13 +269,13 @@ async function copyComment(comment: CommentType) {
.nc-audit-comment-block {
&::before {
content: '';
- @apply absolute -top-4 left-15.8 h-4 border-l-1 border-gray-300;
+ @apply absolute -top-4 left-15.8 h-4 border-l-1 border-nc-border-gray-dark;
}
}
.nc-audit-comment-block {
&::after {
content: '';
- @apply absolute -bottom-4 left-15.8 h-4 border-l-1 border-gray-300;
+ @apply absolute -bottom-4 left-15.8 h-4 border-l-1 border-nc-border-gray-dark;
}
}
</style>
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/index.vue b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/index.vue
index 8f3cb9872e..683bba5ec2 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/index.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Discussion/index.vue
@@ -79,10 +79,10 @@ export default {
}"
>
<div class="w-[680px] max-w-full flex-grow flex flex-col px-6 2xl:px-0">
- <div class="w-full h-0 flex-grow ml-15.8 border-l-1 border-gray-300" />
+ <div class="w-full h-0 flex-grow ml-15.8 border-l-1 border-nc-border-gray-dark" />
</div>
<div v-if="hasMoreAudits" class="w-[680px] max-w-full fflex-grow-0 flex-shrink-0 flex flex-col px-6 2xl:px-0">
- <div class="w-full h-15 flex-grow-0 flex-shrink-0 ml-15.8 border-l-1 border-gray-300 relative">
+ <div class="w-full h-15 flex-grow-0 flex-shrink-0 ml-15.8 border-l-1 border-nc-border-gray-dark relative">
<NcButton
size="small"
type="secondary"
@@ -104,7 +104,7 @@ export default {
</div>
<div
v-if="isUIAllowed('commentEdit')"
- class="w-full border-t border-gray-200 px-6 2xl:px-0 sticky bottom-0 pb-4 -mb-4 bg-white z-10"
+ class="w-full border-t border-nc-border-gray-medium px-6 2xl:px-0 sticky bottom-0 pb-4 -mb-4 bg-nc-bg-default z-10"
>
<div class="font-bold my-3">Add a comment</div>
<SmartsheetExpandedFormRichComment
@@ -112,7 +112,7 @@ export default {
v-model:value="newCommentText"
:hide-options="false"
placeholder="Comment..."
- class="expanded-form-comment-input !py-2 !px-2 cursor-text border-1 rounded-lg !text-gray-800 !text-small !leading-18px !max-h-[240px] bg-white !w-auto"
+ class="expanded-form-comment-input !py-2 !px-2 cursor-text border-1 rounded-lg !text-nc-content-gray !text-small !leading-18px !max-h-[240px] bg-nc-bg-default !w-auto"
data-testid="expanded-form-comment-input"
:autofocus="isExpandedFormCommentMode"
@focus="isExpandedFormCommentMode = false"
@@ -123,7 +123,7 @@ export default {
/>
</div>
<div v-else class="w-full px-6 2xl:px-0">
- <div class="w-full h-4 flex-grow ml-15.8 -mb-4 border-l-1 border-gray-300" />
+ <div class="w-full h-4 flex-grow ml-15.8 -mb-4 border-l-1 border-nc-border-gray-dark" />
</div>
<div ref="refAuditsEnd" />
@@ -131,7 +131,7 @@ export default {
</div>
<div
v-if="showRightSections && !isUnsavedDuplicatedRecordExist"
- class="nc-comments-drawer border-l-1 relative border-gray-200 bg-white w-1/3 max-w-[400px] min-w-0 h-full xs:hidden rounded-br-2xl"
+ class="nc-comments-drawer border-l-1 relative border-nc-border-gray-medium bg-nc-bg-default w-1/3 max-w-[400px] min-w-0 h-full xs:hidden rounded-br-2xl"
:class="{
active: commentsDrawer && isUIAllowed('commentList'),
}"
@@ -147,7 +147,7 @@ export default {
box-shadow: none;
&:focus,
&:focus-within {
- @apply min-h-16 !bg-white border-brand-500;
+ @apply min-h-16 !bg-nc-bg-default border-nc-border-brand;
box-shadow: 0px 0px 0px 2px rgba(51, 102, 255, 0.24);
}
&::placeholder {
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/ColumnList.vue b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/ColumnList.vue
index 3f31c9b60f..d1b35d214b 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/ColumnList.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/ColumnList.vue
@@ -105,7 +105,7 @@ const revertLocalOnlyChanges = (col: string) => {
>
<template #default="{ isAllowed }">
<SmartsheetDivDataCell
- class="flex-1 bg-white px-1 min-h-8 flex items-center relative"
+ class="flex-1 bg-nc-bg-default px-1 min-h-8 flex items-center relative"
:class="{
'w-full': props.forceVerticalMode,
'!select-text nc-system-field bg-nc-bg-gray-extralight !text-nc-content-inverted-primary-disabled cursor-pointer':
@@ -141,7 +141,7 @@ const revertLocalOnlyChanges = (col: string) => {
class="flex h-full items-center justify-center cursor-pointer relative"
@click="revertLocalOnlyChanges(col.title)"
>
- <GeneralIcon class="absolute right-0 top-0 text-gray-500 hover:text-gray-700 my-auto" icon="reload" />
+ <GeneralIcon class="absolute right-0 top-0 text-nc-content-gray-muted hover:text-nc-content-gray-subtle my-auto" icon="reload" />
</div>
</div>
</div>
@@ -173,7 +173,7 @@ const revertLocalOnlyChanges = (col: string) => {
&.nc-readonly-div-data-cell,
&.nc-system-field {
- @apply !border-gray-200;
+ @apply !border-nc-border-gray-medium;
.nc-cell,
.nc-virtual-cell {
@@ -183,7 +183,7 @@ const revertLocalOnlyChanges = (col: string) => {
&.nc-readonly-div-data-cell:focus-within,
&.nc-system-field:focus-within {
- @apply !border-gray-200;
+ @apply !border-nc-border-gray-medium;
}
&:focus-within:not(.nc-readonly-div-data-cell):not(.nc-system-field) {
@@ -212,12 +212,12 @@ const revertLocalOnlyChanges = (col: string) => {
}
:deep(.nc-virtual-cell-qrcode) {
img {
- @apply !h-full border-1 border-solid border-gray-200 rounded;
+ @apply !h-full border-1 border-solid border-nc-border-gray-medium rounded;
}
}
:deep(.nc-virtual-cell-barcode) {
.nc-barcode-container {
- @apply border-1 rounded-lg border-gray-200 h-[64px] max-w-full p-2;
+ @apply border-1 rounded-lg border-nc-border-gray-medium h-[64px] max-w-full p-2;
svg {
@apply !h-full;
}
@@ -232,11 +232,11 @@ const revertLocalOnlyChanges = (col: string) => {
.nc-mentioned-cell {
box-shadow: 0px 0px 0px 2px var(--ant-primary-color-outline) !important;
- @apply !border-brand-500 !border-1;
+ @apply !border-nc-border-brand !border-1;
}
.nc-data-cell:focus-within {
- @apply !border-1 !border-brand-500;
+ @apply !border-1 !border-nc-border-brand;
}
:deep(.nc-system-field input) {
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/Columns.vue b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/Columns.vue
index 351ceaceb1..b7787f9d04 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/Columns.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/Columns.vue
@@ -28,10 +28,10 @@ const showHiddenFields = ref(false)
:is-loading="isLoading"
/>
<div v-if="hiddenFields.length > 0" class="flex w-full <lg:(px-1) items-center py-6">
- <div class="flex-grow h-px mr-1 bg-gray-100" />
+ <div class="flex-grow h-px mr-1 bg-nc-bg-gray-light" />
<NcButton
:size="isMobileMode ? 'medium' : 'small'"
- class="flex-shrink !text-sm overflow-hidden !text-gray-500 !font-weight-500"
+ class="flex-shrink !text-sm overflow-hidden !text-nc-content-gray-muted !font-weight-500"
type="secondary"
@click="showHiddenFields = !showHiddenFields"
>
@@ -39,7 +39,7 @@ const showHiddenFields = ref(false)
{{ hiddenFields.length > 1 ? `fields` : `field` }}
<GeneralIcon icon="chevronDown" :class="showHiddenFields ? 'transform rotate-180' : ''" class="ml-1" />
</NcButton>
- <div class="flex-grow h-px ml-1 bg-gray-100" />
+ <div class="flex-grow h-px ml-1 bg-nc-bg-gray-light" />
</div>
<SmartsheetExpandedFormPresentorsFieldsColumnList
v-if="hiddenFields.length > 0 && showHiddenFields"
diff --git a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/index.vue b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/index.vue
index 4383f7f84e..a9dfa6675a 100644
--- a/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/index.vue
+++ b/packages/nc-gui/components/smartsheet/expanded-form/presentors/Fields/index.vue
@@ -69,13 +69,13 @@ export default {
v-if="canEdit"
class="w-full flex items-center justify-end px-2 xs:(p-0 gap-x-4 justify-between)"
:class="{
- 'xs(border-t-1 border-gray-200)': !isNew,
+ 'xs(border-t-1 border-nc-border-gray-medium)': !isNew,
}"
>
<div v-if="!isNew && isMobileMode" class="p-2">
<NcDropdown placement="bottomRight" class="p-2">
<NcButton :disabled="isLoading" class="nc-expand-form-more-actions" type="secondary" size="small">
- <GeneralIcon :class="isLoading ? 'text-gray-300' : 'text-gray-700'" class="text-md" icon="threeDotVertical" />
+ <GeneralIcon :class="isLoading ? 'text-nc-content-brand-hover' : 'text-nc-content-gray-subtle'" class="text-md" icon="threeDotVertical" />
</NcButton>
<template #overlay>
@@ -103,7 +103,7 @@ export default {
<NcMenuItem
v-e="['c:row-expand:delete']"
:class="{
- '!text-red-500 !hover:bg-red-50': isAllowed,
+ '!text-nc-content-red-medium !hover:bg-nc-bg-red-light': isAllowed,
}"
:disabled="!isAllowed"
@click="!isNew && emits('deleteRow')"
@@ -144,7 +144,7 @@ export default {
</div>
<div
v-if="showRightSections && !isUnsavedDuplicatedRecordExist"
- class="nc-comments-drawer border-l-1 relative border-gray-200 bg-gray-50 w-1/3 max-w-[400px] min-w-0 h-full xs:hidden rounded-br-2xl"
+ class="nc-comments-drawer border-l-1 relative border-nc-border-gray-medium bg-nc-bg-gray-extralight w-1/3 max-w-[400px] min-w-0 h-full xs:hidden rounded-br-2xl"
:class="{
active: commentsDrawer && isUIAllowed('commentList'),
}"
diff --git a/packages/nc-gui/migrate-colors.js b/packages/nc-gui/migrate-colors.js
index f9dd0d8020..5eca91d501 100644
--- a/packages/nc-gui/migrate-colors.js
+++ b/packages/nc-gui/migrate-colors.js
@@ -37,7 +37,7 @@ const colorMappingConflicts = {
{
token: 'text-nc-content-gray-muted',
priority: 50,
- context: ['muted', 'disabled', 'placeholder', 'hint', 'caption'],
+ context: ['muted', 'disabled', 'placeholder', 'hint', 'caption', 'GeneralIcon'],
usage: 'Primary choice for muted text',
},
{