This commit is contained in:
parent
4aa55f7b27
commit
bc65438225
5 changed files with 11 additions and 66 deletions
|
@ -60,10 +60,6 @@
|
|||
--b3-tooltips-second-color: #7d7c7a;
|
||||
--b3-tooltips-shadow: 0 2px 8px rgba(0, 0, 0, .1);
|
||||
|
||||
/* av */
|
||||
--b3-av-hover: #e8e8e9;
|
||||
--b3-av-background-hl: #e8eefc;
|
||||
|
||||
/* 为空提示 */
|
||||
--b3-empty-color: var(--b3-theme-on-surface-light);
|
||||
|
||||
|
|
|
@ -59,10 +59,6 @@
|
|||
--b3-tooltips-second-color: #7d7c7a;
|
||||
--b3-tooltips-shadow: 0 2px 8px rgba(0, 0, 0, .3);
|
||||
|
||||
/* av */
|
||||
--b3-av-hover: #2a2a2a;
|
||||
--b3-av-background-hl: #28324e;
|
||||
|
||||
/* 为空提示 */
|
||||
--b3-empty-color: var(--b3-theme-on-surface);
|
||||
|
||||
|
|
|
@ -143,7 +143,7 @@
|
|||
&--hl {
|
||||
&:not(.av__row--header) .av__cell,
|
||||
&:not(.av__row--header) .av__firstcol {
|
||||
background-color: var(--b3-av-background-hl) !important;
|
||||
background-color: var(--b3-theme-primary-lightest);
|
||||
}
|
||||
|
||||
.av__firstcol svg {
|
||||
|
@ -177,10 +177,6 @@
|
|||
opacity: 1;
|
||||
}
|
||||
|
||||
.av__colsticky {
|
||||
background-color: var(--b3-parent-background); // 保证盯住时无计算结果的列不被覆盖
|
||||
}
|
||||
|
||||
.av__calc {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
@ -220,7 +216,7 @@
|
|||
}
|
||||
|
||||
&:hover {
|
||||
background-color: var(--b3-av-hover);
|
||||
background-color: var(--b3-list-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -236,7 +232,7 @@
|
|||
|
||||
&:hover,
|
||||
&:focus {
|
||||
background-color: var(--b3-av-hover);
|
||||
background-color: var(--b3-list-hover);
|
||||
box-shadow: none;
|
||||
}
|
||||
}
|
||||
|
@ -302,13 +298,13 @@
|
|||
}
|
||||
|
||||
&--select {
|
||||
background-color: var(--b3-menu-background);
|
||||
background-color: var(--b3-theme-primary-lightest);
|
||||
box-shadow: 2px 2px 0 var(--b3-theme-primary-lighter) inset, -2px -2px 0 var(--b3-theme-primary-lighter) inset;
|
||||
border-radius: var(--b3-border-radius);
|
||||
}
|
||||
|
||||
&--active {
|
||||
background-color: var(--b3-menu-background);
|
||||
background-color: var(--b3-theme-primary-lightest);
|
||||
}
|
||||
|
||||
&--header {
|
||||
|
@ -319,7 +315,7 @@
|
|||
border-right-color: transparent;
|
||||
|
||||
&:hover {
|
||||
background-color: var(--b3-av-hover);
|
||||
background-color: var(--b3-list-hover);
|
||||
}
|
||||
|
||||
.av__celltext {
|
||||
|
@ -434,11 +430,7 @@
|
|||
left: 0;
|
||||
z-index: 2; // 需大于 av__widthdrag,否则横行滚动后,拖拽会悬浮于 stick 列上
|
||||
display: flex;
|
||||
|
||||
&.av__firstcol,
|
||||
& > div:not(.av__cell--select):not(.av__cell--active):not(.av__calc--ashow) {
|
||||
background-color: var(--b3-parent-background);
|
||||
}
|
||||
background-color: var(--b3-parent-background);
|
||||
}
|
||||
|
||||
&__widthdrag {
|
||||
|
@ -531,45 +523,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
.protyle-wysiwyg--select {
|
||||
.av__row--header,
|
||||
.av__row--footer,
|
||||
.av__row--footer .av__colsticky,
|
||||
.av__row--select .av__cell,
|
||||
.av__colsticky.av__firstcol,
|
||||
.av__colsticky > div,
|
||||
.av__cell--select,
|
||||
.av__cell--active,
|
||||
.av__counter {
|
||||
background-color: var(--b3-av-background-hl) !important;
|
||||
}
|
||||
}
|
||||
|
||||
.protyle-wysiwyg--hl {
|
||||
.av__row--header,
|
||||
.av__row--footer,
|
||||
.av__row--footer .av__colsticky,
|
||||
.av__row--select .av__cell,
|
||||
.av__colsticky.av__firstcol,
|
||||
.av__colsticky > div,
|
||||
.av__cell--select,
|
||||
.av__cell--active,
|
||||
.av__counter {
|
||||
background-color: var(--b3-av-background-hl) !important;
|
||||
transition: var(--b3-background-transition);
|
||||
}
|
||||
}
|
||||
|
||||
.dragover__top,
|
||||
.dragover__bottom {
|
||||
.av__colsticky {
|
||||
&.av__firstcol,
|
||||
& > div:not(.av__cell--select):not(.av__cell--active):not(.av__calc--ashow) {
|
||||
background-color: transparent;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
img.av__cellassetimg {
|
||||
max-height: calc(1.625em - 2px);
|
||||
border-radius: var(--b3-border-radius);
|
||||
|
|
|
@ -94,7 +94,7 @@ export const avRender = (element: Element, protyle: IProtyle, cb?: () => void, v
|
|||
e.dataset.pageSize = data.pageSize.toString();
|
||||
}
|
||||
// header
|
||||
let tableHTML = '<div class="av__row av__row--header"><div class="av__firstcol av__colsticky"><svg><use xlink:href="#iconUncheck"></use></svg></div>';
|
||||
let tableHTML = '<div class="av__row av__row--header"><div class="av__colsticky"><div class="av__firstcol"><svg><use xlink:href="#iconUncheck"></use></svg></div></div>';
|
||||
let calcHTML = "";
|
||||
let pinIndex = -1;
|
||||
let pinMaxIndex = -1;
|
||||
|
@ -169,7 +169,7 @@ style="width: ${column.width || "200px"}">${getCalcValue(column) || '<svg><use x
|
|||
if (pinIndex > -1) {
|
||||
tableHTML += '<div class="av__colsticky"><div class="av__firstcol"><svg><use xlink:href="#iconUncheck"></use></svg></div>';
|
||||
} else {
|
||||
tableHTML += '<div class="av__firstcol av__colsticky"><svg><use xlink:href="#iconUncheck"></use></svg></div>';
|
||||
tableHTML += '<div class="av__colsticky"><div class="av__firstcol"><svg><use xlink:href="#iconUncheck"></use></svg></div></div>';
|
||||
}
|
||||
|
||||
row.cells.forEach((cell, index) => {
|
||||
|
|
|
@ -109,10 +109,10 @@ export const insertAttrViewBlockAnimation = (protyle: IProtyle, blockElement: El
|
|||
if (blockElement.querySelector('.av__views [data-type="av-sort"]').classList.contains("block__icon--active")) {
|
||||
previousElement = blockElement.querySelector(".av__row--util").previousElementSibling;
|
||||
}
|
||||
let colHTML = '<div class="av__firstcol av__colsticky"><svg><use xlink:href="#iconUncheck"></use></svg></div>';
|
||||
let colHTML = '<div class="av__colsticky"><div class="av__firstcol"><svg><use xlink:href="#iconUncheck"></use></svg></div></div>';
|
||||
const pinIndex = previousElement.querySelectorAll(".av__colsticky .av__cell").length - 1;
|
||||
if (pinIndex > -1) {
|
||||
colHTML = '<div class="av__colsticky"><div class="av__firstcol av__colsticky"><svg><use xlink:href="#iconUncheck"></use></svg></div>';
|
||||
colHTML = '<div class="av__colsticky"><div class="av__firstcol"><svg><use xlink:href="#iconUncheck"></use></svg></div>';
|
||||
}
|
||||
previousElement.querySelectorAll(".av__cell").forEach((item: HTMLElement, index) => {
|
||||
let lineNumber = "";
|
||||
|
|
Loading…
Add table
Reference in a new issue