vendor: amis 6.13.0 base (fork root)
This commit is contained in:
166
packages/amis-editor-core/scss/control/_api-control.scss
Normal file
166
packages/amis-editor-core/scss/control/_api-control.scss
Normal file
@@ -0,0 +1,166 @@
|
||||
.ae-ApiControl {
|
||||
position: relative;
|
||||
|
||||
&.border {
|
||||
padding: #{px2rem(10px)};
|
||||
border-radius: $Editor-borderRadius;
|
||||
border: 1px solid #e6e6e8;
|
||||
}
|
||||
|
||||
&-header {
|
||||
@include flexBox();
|
||||
height: #{px2rem(24px)};
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: px2rem(-26px);
|
||||
}
|
||||
|
||||
&-content {
|
||||
@include flexBox();
|
||||
align-items: stretch;
|
||||
|
||||
.ae-ApiControl-input {
|
||||
background: var(--Form-input-bg);
|
||||
border: var(--Form-input-borderWidth) solid var(--Form-input-borderColor);
|
||||
border-radius: var(--Form-input-borderRadius);
|
||||
line-height: var(--Form-input-lineHeight);
|
||||
padding: var(--Form-input-paddingY) var(--Form-input-paddingX);
|
||||
font-size: var(--Form-input-fontSize);
|
||||
display: flex;
|
||||
flex-flow: row nowrap;
|
||||
justify-content: flex-start;
|
||||
align-items: center;
|
||||
flex: 1;
|
||||
margin-right: #{px2rem(10px)};
|
||||
// max-width: calc(100% - 52px);
|
||||
height: var(--Button--sm-height);
|
||||
|
||||
& > input {
|
||||
flex-basis: 5rem;
|
||||
flex-grow: 1;
|
||||
outline: 0;
|
||||
background: transparent;
|
||||
border: 0;
|
||||
color: var(--Form-input-color);
|
||||
width: 100%;
|
||||
height: calc(var(--Form-input-lineHeight) * var(--Form-input-fontSize));
|
||||
}
|
||||
|
||||
.ae-ApiControl-setting-button {
|
||||
height: unset;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-highlight {
|
||||
width: 100%;
|
||||
max-width: calc(100% - var(--fontSizeLg));
|
||||
display: flex;
|
||||
flex-flow: row nowrap;
|
||||
justify-content: flex-start;
|
||||
align-items: center;
|
||||
|
||||
&-tag {
|
||||
display: inline-block;
|
||||
background: #007bff;
|
||||
padding: 3px 5px;
|
||||
margin: 0 1px;
|
||||
color: #fff;
|
||||
font-size: 12px;
|
||||
line-height: 14px;
|
||||
height: 20px;
|
||||
border-radius: #{px2rem(4px)};
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
max-width: 90%;
|
||||
}
|
||||
}
|
||||
|
||||
&-icon {
|
||||
width: var(--fontSizeLg) !important;
|
||||
height: var(--fontSizeLg) !important;
|
||||
}
|
||||
|
||||
&-dialog {
|
||||
&-body {
|
||||
margin: #{px2rem(16px)} 0 #{px2rem(24px)};
|
||||
|
||||
.ae-ApiControl-form {
|
||||
@include panel-sm-content();
|
||||
.ae-ApiControl-tabContent {
|
||||
max-height: 560px;
|
||||
overflow-x: hidden;
|
||||
overflow-y: auto;
|
||||
border-bottom: 1px solid var(--borderColor);
|
||||
}
|
||||
|
||||
.ae-ApiControl-title {
|
||||
border-left: none;
|
||||
font-weight: bold;
|
||||
color: #333;
|
||||
line-height: #{px2rem(20px)};
|
||||
padding-left: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-picker {
|
||||
&-dialog {
|
||||
&-content {
|
||||
height: 500px;
|
||||
max-height: 500px;
|
||||
overflow-x: hidden;
|
||||
overflow-y: auto;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ae-ApiControl-PickerBtn {
|
||||
padding: 0;
|
||||
|
||||
&:hover > svg path {
|
||||
stroke: var(--primary);
|
||||
color: var(--primary);
|
||||
}
|
||||
}
|
||||
|
||||
.ae-AdaptorControl,
|
||||
.ae-FunctionEditorControl {
|
||||
&-func {
|
||||
&-header,
|
||||
&-footer {
|
||||
padding-left: 8px;
|
||||
font-size: 12px;
|
||||
}
|
||||
&-header {
|
||||
margin-bottom: -20px;
|
||||
}
|
||||
&-footer {
|
||||
margin-top: -20px;
|
||||
}
|
||||
&-arg {
|
||||
padding: 0;
|
||||
height: auto;
|
||||
font-size: 12px;
|
||||
vertical-align: baseline;
|
||||
color: var(--primary);
|
||||
}
|
||||
&-editor {
|
||||
margin-bottom: 0;
|
||||
.cxd-EditorControl {
|
||||
padding-top: 20px;
|
||||
padding-bottom: 20px;
|
||||
}
|
||||
.cxd-MonacoEditor-placeholder {
|
||||
line-height: 18px;
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
}
|
||||
&-desc-tooltip {
|
||||
max-width: 500px;
|
||||
}
|
||||
}
|
||||
47
packages/amis-editor-core/scss/control/_badge-control.scss
Normal file
47
packages/amis-editor-core/scss/control/_badge-control.scss
Normal file
@@ -0,0 +1,47 @@
|
||||
.ae-BadgeControl {
|
||||
&-switch {
|
||||
@include flexBox();
|
||||
margin-bottom: var(--gap-base);
|
||||
}
|
||||
|
||||
&-form {
|
||||
@include panel-group-bg();
|
||||
}
|
||||
|
||||
&-combo {
|
||||
background: #fafafa;
|
||||
padding: var(--gap-sm);
|
||||
border: 1px dashed transparent;
|
||||
border-radius: #{$Editor-borderRadius};
|
||||
|
||||
&:hover {
|
||||
border-color: #{$Editor-theme-color};
|
||||
}
|
||||
}
|
||||
|
||||
&-buttonGroup {
|
||||
> div {
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
|
||||
> div {
|
||||
flex-grow: 0 !important;
|
||||
min-width: auto !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-position {
|
||||
&--clockwise {
|
||||
> i {
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
}
|
||||
|
||||
&--antiClockwise {
|
||||
> i {
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
174
packages/amis-editor-core/scss/control/_crud2-control.scss
Normal file
174
packages/amis-editor-core/scss/control/_crud2-control.scss
Normal file
@@ -0,0 +1,174 @@
|
||||
/**
|
||||
* @file crud2-control.scss
|
||||
* @desc CRUD2相关控件及样式
|
||||
*/
|
||||
|
||||
.ae-CRUDConfigControl {
|
||||
margin-bottom: var(--Form-item-gap);
|
||||
|
||||
&-list {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border-radius: 4px;
|
||||
border: 1px solid #e8e9eb;
|
||||
padding-top: 3px;
|
||||
padding-bottom: 3px;
|
||||
|
||||
&-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
height: 30px;
|
||||
padding: 0 var(--gap-sm);
|
||||
|
||||
&.is-draggable:hover {
|
||||
background-color: #f9f9f9;
|
||||
cursor: move;
|
||||
}
|
||||
|
||||
&-dragger {
|
||||
cursor: move;
|
||||
margin: 0 var(--gap-sm) 0 0;
|
||||
color: rgba(232, 233, 235, 1);
|
||||
}
|
||||
|
||||
&-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
max-width: 140px;
|
||||
|
||||
& > span {
|
||||
max-width: 100%;
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
font-weight: 500;
|
||||
color: #151b26;
|
||||
}
|
||||
}
|
||||
|
||||
&-actions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-right: var(--gap-xs);
|
||||
|
||||
& > button {
|
||||
color: #151b26;
|
||||
margin: 0;
|
||||
padding-left: 0;
|
||||
padding-right: 0;
|
||||
|
||||
&:not(:last-child) {
|
||||
margin-right: var(--gap-sm);
|
||||
}
|
||||
|
||||
& > svg {
|
||||
width: px2rem(16px);
|
||||
height: px2rem(16px);
|
||||
|
||||
&.icon-share-link {
|
||||
width: px2rem(14px);
|
||||
height: px2rem(14px);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-tag {
|
||||
cursor: auto;
|
||||
background-color: transparent;
|
||||
border: 1px solid #2468f2;
|
||||
color: #2468f2;
|
||||
border-radius: 2px;
|
||||
line-height: #{px2rem(18px)};
|
||||
height: #{px2rem(20px)};
|
||||
margin-right: #{px2rem(8px)};
|
||||
scale: 0.9;
|
||||
max-width: 80px;
|
||||
|
||||
&--cascading {
|
||||
color: #531dab;
|
||||
border-color: #531dab;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-placeholder {
|
||||
color: #b4b6ba;
|
||||
padding-top: px2rem(10px);
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
&-header {
|
||||
display: flex;
|
||||
flex-flow: row nowrap;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
& > span:nth-child(1) {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
&-actions {
|
||||
display: flex;
|
||||
flex-flow: row nowrap;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
&-switch {
|
||||
margin-right: var(--gap-sm);
|
||||
}
|
||||
|
||||
&-divider {
|
||||
width: 1px;
|
||||
height: 16px;
|
||||
margin: 0 4px;
|
||||
background-color: #dfdfdf;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-dropdown {
|
||||
/* margin-bottom: var(--Form-mode-default-labelGap); */
|
||||
|
||||
& > button {
|
||||
color: #4c5664;
|
||||
margin: 0;
|
||||
padding-left: 0;
|
||||
padding-right: 0;
|
||||
font-weight: bold;
|
||||
|
||||
& > svg {
|
||||
width: px2rem(14px);
|
||||
height: px2rem(14px);
|
||||
margin-right: var(--gap-xs);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-footer {
|
||||
display: flex;
|
||||
flex-flow: row-reverse nowrap;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-CRUDConfigControl-modal {
|
||||
&-btn-loading {
|
||||
--Spinner-color: #fff;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-FieldSetting-footer {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
bottom: 35px;
|
||||
|
||||
&--form {
|
||||
bottom: 55px;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,98 @@
|
||||
.ae-DataBindingList {
|
||||
display: flex;
|
||||
flex-flow: column nowrap;
|
||||
justify-content: flex-start;
|
||||
align-items: stretch;
|
||||
height: px2rem(350px);
|
||||
border: 1px solid rgba(232, 233, 235, 1);
|
||||
border-radius: px2rem(4px);
|
||||
overflow: scroll;
|
||||
|
||||
&-hint {
|
||||
width: 100%;
|
||||
line-height: 3;
|
||||
text-align: center;
|
||||
color: var(--text--muted-color);
|
||||
}
|
||||
|
||||
&-searchBox {
|
||||
width: auto;
|
||||
padding: #{px2rem(12px)};
|
||||
|
||||
& > div {
|
||||
width: 100% !important;
|
||||
}
|
||||
}
|
||||
|
||||
&-body {
|
||||
@include minScrollBar();
|
||||
flex: 1;
|
||||
overflow-x: hidden;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
&-collapse {
|
||||
border: none;
|
||||
background: #f7f7f9;
|
||||
|
||||
&-title {
|
||||
display: block !important;
|
||||
padding: #{px2rem(5px)} #{px2rem(12px)};
|
||||
background: transparent !important;
|
||||
font-size: var(--fontSizeSm);
|
||||
font-weight: bold;
|
||||
position: relative;
|
||||
|
||||
.expandIcon {
|
||||
font-size: var(--fontSizeSm);
|
||||
line-height: var(--fontSizeXl);
|
||||
transform-origin: #{px2rem(7px)} #{px2rem(9px)};
|
||||
transition: transform 0.2s;
|
||||
position: absolute;
|
||||
right: #{px2rem(6px)};
|
||||
margin-top: 3px;
|
||||
}
|
||||
}
|
||||
|
||||
&-body {
|
||||
background: #fff;
|
||||
color: #303540;
|
||||
|
||||
> div {
|
||||
padding: 5px 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-item {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: baseline;
|
||||
cursor: pointer;
|
||||
padding: 0 var(--gap-xl); // 和标题对齐不好看,加个缩进
|
||||
height: px2rem(32px);
|
||||
line-height: px2rem(32px);
|
||||
color: #303540;
|
||||
font-weight: 400;
|
||||
|
||||
span {
|
||||
flex-grow: 1;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
background: var(--Tree-item-onHover-bg);
|
||||
}
|
||||
|
||||
&.is-active {
|
||||
color: var(--primary);
|
||||
background: var(--Tree-item-onHover-bg);
|
||||
}
|
||||
}
|
||||
|
||||
&-empty {
|
||||
color: #b4b6ba;
|
||||
padding-top: px2rem(10px);
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,117 @@
|
||||
.ae-DateShortCutControl {
|
||||
&-header {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
height: #{px2rem(24px)};
|
||||
margin-bottom: #{px2rem(5px)};
|
||||
|
||||
label {
|
||||
margin-right: #{px2rem(16px)};
|
||||
font-size: #{px2rem(12px)};
|
||||
color: #5e626a;
|
||||
}
|
||||
|
||||
&-icon {
|
||||
flex: 1;
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
|
||||
&-footer {
|
||||
margin-top: #{px2rem(10px)};
|
||||
|
||||
&-btn {
|
||||
display: inline-block;
|
||||
width: 50%;
|
||||
padding-right: #{px2rem(5px)};
|
||||
|
||||
&:last-child {
|
||||
padding-left: #{px2rem(5px)};
|
||||
padding-right: 0;
|
||||
}
|
||||
|
||||
> div {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
button {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
ul {
|
||||
width: 100%;
|
||||
min-width: unset;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-content {
|
||||
@include flexBox(column, flex-start);
|
||||
@include minScrollBar();
|
||||
margin: 0;
|
||||
padding: #{px2rem(3px)} 0;
|
||||
border-radius: $Editor-borderRadius;
|
||||
position: relative;
|
||||
background: #f7f7f9;
|
||||
|
||||
&::before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: -6px;
|
||||
left: 10px;
|
||||
border-left: 9px solid transparent;
|
||||
border-right: 9px solid transparent;
|
||||
border-bottom: 9px solid #f7f7f9;
|
||||
}
|
||||
|
||||
.ae-DateShortCutControlItem {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
padding: #{px2rem(5px)} #{px2rem(10px)};
|
||||
min-height: #{px2rem(38px)};
|
||||
align-items: baseline;
|
||||
|
||||
&:hover {
|
||||
background: #e9effd;
|
||||
}
|
||||
|
||||
&-dragging {
|
||||
height: 0 !important;
|
||||
padding: 0;
|
||||
border-top: 2px solid var(--primary);
|
||||
overflow: hidden;
|
||||
background: #e9effd;
|
||||
}
|
||||
|
||||
&-dragBar {
|
||||
display: inline-flex;
|
||||
margin-left: 0;
|
||||
margin-right: var(--gap-sm);
|
||||
margin-top: -4px;
|
||||
cursor: move;
|
||||
color: #8c8c8c;
|
||||
}
|
||||
|
||||
&-content {
|
||||
display: inline-block;
|
||||
flex-grow: 1;
|
||||
max-width: calc(100% - 32px);
|
||||
text-align: left;
|
||||
padding: 0 #{px2rem(5px)};
|
||||
|
||||
&-label {
|
||||
line-height: var(--input-size-default-height);
|
||||
}
|
||||
}
|
||||
|
||||
&-close {
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-empty {
|
||||
@include flexBox(column, center);
|
||||
height: #{px2rem(38px)};
|
||||
}
|
||||
}
|
||||
515
packages/amis-editor-core/scss/control/_event-action.scss
Normal file
515
packages/amis-editor-core/scss/control/_event-action.scss
Normal file
@@ -0,0 +1,515 @@
|
||||
.ae-event-control {
|
||||
font-size: #{px2rem(12px)};
|
||||
&-header-oldentry {
|
||||
height: 100px;
|
||||
.add-event-dropdown {
|
||||
top: 47px;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
&-header {
|
||||
width: 100%;
|
||||
padding: #{px2rem(12px)};
|
||||
background: #fff;
|
||||
z-index: 1;
|
||||
margin-top: 1px;
|
||||
.add-event-dropdown {
|
||||
button {
|
||||
top: 44px;
|
||||
width: 100%;
|
||||
color: #2468f2;
|
||||
border: #{px2rem(1px)} solid #2468f2;
|
||||
border-radius: #{px2rem(4px)};
|
||||
span {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
.add-event-dropdown-global-event {
|
||||
position: relative;
|
||||
&::after {
|
||||
position: absolute;
|
||||
content: '全局事件';
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 0 6px;
|
||||
right: 4px;
|
||||
top: 4px;
|
||||
bottom: 4px;
|
||||
font-size: 12px;
|
||||
color: #fff;
|
||||
background-color: #2468f2;
|
||||
border-radius: 4px;
|
||||
transform: scale(0.8);
|
||||
transform-origin: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
ul {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
&-header-m {
|
||||
margin-top: #{px2rem(45px)} !important;
|
||||
}
|
||||
&-content-m {
|
||||
margin-top: #{px2rem(97px)} !important;
|
||||
}
|
||||
&-content-l {
|
||||
margin-top: #{px2rem(150px)} !important;
|
||||
}
|
||||
&-content {
|
||||
padding: 0;
|
||||
margin-top: 0;
|
||||
.icon {
|
||||
cursor: pointer;
|
||||
color: #30343f;
|
||||
width: #{px2rem(16px)};
|
||||
height: #{px2rem(16px)};
|
||||
&:hover {
|
||||
color: #2468f2;
|
||||
}
|
||||
}
|
||||
.event-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
&-header {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
background: #f2f2f4;
|
||||
border: #{px2rem(1px)} solid #d4d6d9;
|
||||
border-left: none;
|
||||
border-right: none;
|
||||
padding: 0 12px;
|
||||
font-weight: 500;
|
||||
align-items: center;
|
||||
height: #{px2rem(32px)};
|
||||
&-toolbar {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
& > div {
|
||||
margin-right: #{px2rem(12px)};
|
||||
&:last-child {
|
||||
margin-right: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.event-label {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.event-label-key {
|
||||
flex: 1;
|
||||
max-width: 100px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
.global-event-tip {
|
||||
width: 48px;
|
||||
display: flex;
|
||||
> span {
|
||||
transform: scale(0.7);
|
||||
transform-origin: left;
|
||||
background-color: #2468f2;
|
||||
border-radius: 4px;
|
||||
font-size: 12px;
|
||||
color: #fff;
|
||||
padding: 4px 6px;
|
||||
flex-shrink: 0;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
&-desc {
|
||||
margin: #{px2rem(12px)};
|
||||
color: #84868c;
|
||||
button > svg {
|
||||
width: #{px2rem(12px)};
|
||||
height: #{px2rem(12px)};
|
||||
}
|
||||
}
|
||||
&:last-child {
|
||||
.event-item-header {
|
||||
border-bottom: #{px2rem(1px)} solid #d4d6d9;
|
||||
}
|
||||
}
|
||||
.no-bd-btm {
|
||||
border-bottom: none;
|
||||
}
|
||||
.item-content {
|
||||
@include flexBox(column, flex-start);
|
||||
@include minScrollBar();
|
||||
margin: 0;
|
||||
padding-left: #{px2rem(12px)};
|
||||
padding-right: #{px2rem(12px)};
|
||||
padding-top: #{px2rem(12px)};
|
||||
background: #ffffff;
|
||||
list-style-type: none;
|
||||
.ae-option-control-item {
|
||||
background: #f7f7f9;
|
||||
width: 100%;
|
||||
padding: #{px2rem(8px)};
|
||||
margin-bottom: #{px2rem(12px)};
|
||||
border-radius: #{px2rem(4px)};
|
||||
border: #{px2rem(1px)} solid transparent;
|
||||
&:hover {
|
||||
border: #{px2rem(1px)} solid #2468f2;
|
||||
}
|
||||
.action-control-header {
|
||||
@include flexBox(row, space-between);
|
||||
&-left,
|
||||
&-right {
|
||||
color: #303540;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.icon {
|
||||
color: #84868c;
|
||||
&:hover {
|
||||
color: #2468f2;
|
||||
}
|
||||
}
|
||||
.action-item-actiontype {
|
||||
max-width: #{px2rem(144px)};
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
}
|
||||
&-right {
|
||||
& > div {
|
||||
margin-right: #{px2rem(8px)};
|
||||
&:last-child {
|
||||
margin-right: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.action-control-content {
|
||||
color: #84868c;
|
||||
letter-spacing: 0;
|
||||
line-height: #{px2rem(20px)};
|
||||
font-weight: 400;
|
||||
margin-top: #{px2rem(4px)};
|
||||
padding-left: #{px2rem(20px)};
|
||||
max-width: #{px2rem(224px)};
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
.action-desc {
|
||||
display: flex;
|
||||
.desc-tag {
|
||||
max-width: 133px;
|
||||
color: #2468f2;
|
||||
display: inline-block;
|
||||
margin-bottom: -5px;
|
||||
}
|
||||
.variable-left {
|
||||
margin-left: #{px2rem(4px)};
|
||||
}
|
||||
.variable-right {
|
||||
margin-right: #{px2rem(4px)};
|
||||
}
|
||||
.component-action-tag {
|
||||
background-color: rgb(82, 142, 255);
|
||||
display: inline-block;
|
||||
color: #fff;
|
||||
padding: 0 5px;
|
||||
border-radius: 3px;
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
&--dragging {
|
||||
height: 0 !important;
|
||||
padding: 0;
|
||||
border-top: 2px solid var(--primary);
|
||||
overflow: hidden;
|
||||
background: #e9effd;
|
||||
}
|
||||
|
||||
&-dragBar {
|
||||
display: inline-flex;
|
||||
margin-left: 0;
|
||||
line-height: 1;
|
||||
margin-right: #{px2rem(4px)};
|
||||
cursor: move;
|
||||
color: #8c8c8c;
|
||||
}
|
||||
|
||||
&-action {
|
||||
padding-left: 0;
|
||||
padding-right: 0;
|
||||
|
||||
&:not(:last-child) {
|
||||
margin-right: #{px2rem(10px)};
|
||||
}
|
||||
|
||||
&:hover {
|
||||
& > svg,
|
||||
& > svg path {
|
||||
fill: var(--primary);
|
||||
}
|
||||
}
|
||||
|
||||
& > svg,
|
||||
& > svg path {
|
||||
fill: var(--text--muted-color);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.item-footer {
|
||||
@include flexBox(row, flex-end);
|
||||
padding: #{px2rem(5px)};
|
||||
border-bottom-right-radius: $Editor-borderRadius;
|
||||
border-bottom-left-radius: $Editor-borderRadius;
|
||||
border-top: 1px solid #f2f7f3;
|
||||
box-shadow: 0 0 5px rgb(8 14 26 / 6%);
|
||||
clip-path: inset(-5px 0px 0px 0px);
|
||||
}
|
||||
}
|
||||
.no-bd-btm {
|
||||
border-bottom: none;
|
||||
}
|
||||
&-placeholder {
|
||||
color: #84868c;
|
||||
line-height: #{px2rem(24px)};
|
||||
background: url('../static/empty.png');
|
||||
text-align: center;
|
||||
width: #{px2rem(124px)};
|
||||
height: 100%;
|
||||
padding-top: #{px2rem(300px)};
|
||||
background-repeat: no-repeat;
|
||||
background-size: #{px2rem(90px)} #{px2rem(90px)};
|
||||
background-position: 50% 80%;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
&-action-placeholder {
|
||||
width: 100%;
|
||||
min-height: #{px2rem(320px)};
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: #84868c;
|
||||
line-height: #{px2rem(24px)};
|
||||
|
||||
&.no-settings {
|
||||
min-height: #{px2rem(160px)};
|
||||
}
|
||||
|
||||
&-img {
|
||||
width: #{px2rem(64px)};
|
||||
height: #{px2rem(64px)};
|
||||
background: url('../static/empty.png');
|
||||
background-repeat: no-repeat;
|
||||
background-size: 100%;
|
||||
background-position: center;
|
||||
}
|
||||
}
|
||||
|
||||
&-action-js-editor {
|
||||
max-width: #{px2rem(780px)};
|
||||
}
|
||||
}
|
||||
|
||||
.ae-action-config-dialog {
|
||||
*:not(svg) {
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.common-actions {
|
||||
position: absolute;
|
||||
width: 80%;
|
||||
top: #{px2rem(-41px)};
|
||||
left: #{px2rem(128px)};
|
||||
|
||||
.common-actions-label {
|
||||
line-height: #{px2rem(24px)};
|
||||
margin-right: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
.action-config-panel {
|
||||
background: #ffffff;
|
||||
border: 1px solid #e8e9eb;
|
||||
border-radius: 4px;
|
||||
height: #{px2rem(420px)};
|
||||
max-height: #{px2rem(420px)};
|
||||
width: 100%;
|
||||
@include panel-sm-content();
|
||||
|
||||
.action-panel-title {
|
||||
margin: 16px 16px 12px;
|
||||
line-height: 18px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.action-tree-search {
|
||||
margin: 0 16px 8px;
|
||||
&-input {
|
||||
& > div {
|
||||
background: url('../static/search.svg') no-repeat right 12px center;
|
||||
padding-right: 28px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.action-search-list {
|
||||
.search-result-label:hover {
|
||||
background: var(--Tree-item-onHover-bg-pure);
|
||||
}
|
||||
}
|
||||
|
||||
.left-panel {
|
||||
height: 100%;
|
||||
padding-right: 0px;
|
||||
border-right: 1px solid #e8e9eb;
|
||||
max-width: #{px2rem(200px)};
|
||||
.action-tree {
|
||||
height: calc(100% - 88px);
|
||||
border-top: 1px solid #e8e9eb;
|
||||
.action-tree-control {
|
||||
& > div {
|
||||
max-height: 100%;
|
||||
}
|
||||
|
||||
height: 100%;
|
||||
max-height: 100%;
|
||||
padding: 0;
|
||||
& > div > div {
|
||||
margin-top: 82px;
|
||||
height: 64px;
|
||||
background: url('../static/empty.png') center/contain no-repeat;
|
||||
color: transparent;
|
||||
}
|
||||
}
|
||||
|
||||
.action-tree-control {
|
||||
ul {
|
||||
li {
|
||||
& > div {
|
||||
flex-direction: row-reverse;
|
||||
padding-left: 16px;
|
||||
height: 32px;
|
||||
line-height: 32px;
|
||||
span .is-matched {
|
||||
color: #2468f2;
|
||||
}
|
||||
svg {
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
.is-folded > svg {
|
||||
transform: rotate(0);
|
||||
}
|
||||
}
|
||||
& > ul {
|
||||
margin-left: 0;
|
||||
li > div {
|
||||
padding-left: #{px2rem(32px)};
|
||||
}
|
||||
li > div {
|
||||
&:hover {
|
||||
background-color: var(--Tree-item-onHover-bg-pure);
|
||||
}
|
||||
}
|
||||
& > li .is-checked {
|
||||
background: var(--Tree-item-onChekced-bg);
|
||||
&:hover {
|
||||
background-color: var(--Tree-item-onChekced-bg) !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
li .is-checked::before {
|
||||
content: '';
|
||||
background: url('../static/check.svg') no-repeat center center;
|
||||
height: var(--Tree-itemHeight);
|
||||
line-height: var(--Tree-itemHeight);
|
||||
width: 15px;
|
||||
margin-right: 16px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.right-panel {
|
||||
overflow-y: auto;
|
||||
height: 100%;
|
||||
padding: 0 8px 0 0;
|
||||
.action-desc {
|
||||
margin-left: 16px;
|
||||
color: var(--Form-item-color);
|
||||
}
|
||||
|
||||
.cmpt-action-select,
|
||||
.action-btn-width {
|
||||
width: auto;
|
||||
min-width: #{px2rem(320px)};
|
||||
}
|
||||
|
||||
&-container {
|
||||
// max-height: calc(100% - 46px);
|
||||
margin: 0px 16px 16px;
|
||||
.action-panel-title {
|
||||
margin-left: 0;
|
||||
}
|
||||
|
||||
.action-exec-on {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.ae-BaseRemark {
|
||||
margin-left: 0;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
.event-action-combo-item {
|
||||
.event-action-combo {
|
||||
max-width: 380px;
|
||||
.#{$ns}Form-row {
|
||||
width: 380px;
|
||||
}
|
||||
.flex-1 {
|
||||
max-width: 170px;
|
||||
}
|
||||
}
|
||||
width: 380px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ae-event-item-header-tip {
|
||||
background: #070c14d9 !important;
|
||||
box-shadow: 0 px2rem(2px) px2rem(8px) 0 rgba(7, 12, 20, 0.12);
|
||||
border: none;
|
||||
div {
|
||||
font-size: 12px;
|
||||
color: #fff;
|
||||
}
|
||||
& > div {
|
||||
&:after {
|
||||
border-top-color: #070c14d9 !important;
|
||||
border-bottom-color: #070c14d9 !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ae-action-relation-panel {
|
||||
width: 255px;
|
||||
max-height: 360px;
|
||||
overflow: auto;
|
||||
.variables-select-panel-tree {
|
||||
*:not(svg) {
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,51 @@
|
||||
.ae-ExpressionFormulaControl {
|
||||
background-color: #fff;
|
||||
|
||||
.btn-configured,
|
||||
.btn-set-expression {
|
||||
width: 100%;
|
||||
font-size: 12px;
|
||||
}
|
||||
.btn-configured {
|
||||
position: relative;
|
||||
justify-content: left;
|
||||
padding: var(--button-size-sm-paddingTop) 32px
|
||||
var(--button-size-sm-paddingBottom) 4px;
|
||||
line-height: var(--button-size-sm-lineHeight);
|
||||
height: var(--button-size-sm-height);
|
||||
|
||||
& > span {
|
||||
max-width: 100%;
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
background-color: #007bff;
|
||||
padding: 4px 8px;
|
||||
border-radius: 4px;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.icon {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
right: var(--button-size-default-paddingRight);
|
||||
margin: auto 0 !important;
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
fill: var(--Form-input-clearBtn-color);
|
||||
&:hover {
|
||||
fill: var(--Form-input-clearBtn-color-onHover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.btn-configured-tooltip {
|
||||
font-size: 12px;
|
||||
width: 200px;
|
||||
min-height: 40px;
|
||||
|
||||
.CodeMirror {
|
||||
height: auto;
|
||||
}
|
||||
}
|
||||
94
packages/amis-editor-core/scss/control/_feature-control.scss
Normal file
94
packages/amis-editor-core/scss/control/_feature-control.scss
Normal file
@@ -0,0 +1,94 @@
|
||||
.ae-FeatureControl {
|
||||
&-features {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
&Item {
|
||||
display: flex;
|
||||
height: 30px;
|
||||
margin-bottom: 12px;
|
||||
position: relative;
|
||||
align-items: center;
|
||||
|
||||
:not(:last-child) {
|
||||
margin-right: px2rem(8px);
|
||||
}
|
||||
|
||||
&-content {
|
||||
flex-grow: 1;
|
||||
position: relative;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
|
||||
& > .ae-FeatureControlItem-go {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
&-label {
|
||||
flex-grow: 1;
|
||||
height: px2rem(32px);
|
||||
display: block;
|
||||
line-height: px2rem(32px);
|
||||
padding: 0 px2rem(8px);
|
||||
border: var(--Form-input-borderWidth) solid var(--Form-input-borderColor);
|
||||
border-radius: var(--Form-input-borderRadius);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
&-action {
|
||||
padding: 0 6px;
|
||||
svg {
|
||||
width: px2rem(16px);
|
||||
height: px2rem(16px);
|
||||
fill: #000;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
svg {
|
||||
fill: $Editor-theme;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-dragBar {
|
||||
position: absolute;
|
||||
z-index: 2;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
left: 3px;
|
||||
cursor: move;
|
||||
|
||||
& > svg {
|
||||
fill: #e7e7e7;
|
||||
color: #e7e7e7;
|
||||
}
|
||||
}
|
||||
|
||||
&:hover &-dragBar {
|
||||
& > svg {
|
||||
color: transparent;
|
||||
fill: transparent;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-action {
|
||||
display: block;
|
||||
width: 100%;
|
||||
|
||||
&--btn {
|
||||
width: 100%;
|
||||
border-color: $Editor-theme;
|
||||
color: $Editor-theme;
|
||||
}
|
||||
|
||||
&--menus {
|
||||
/* width: calc(100% - 12px);
|
||||
margin-left: 6px; */
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
.ap-Flex {
|
||||
background: #ececec;
|
||||
margin: 0;
|
||||
padding: 6px 10px;
|
||||
|
||||
.ap-Flex-label {
|
||||
font-size: 12px;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.ap-Flex-item {
|
||||
margin-top: 4px;
|
||||
|
||||
> .icon-ButtonList {
|
||||
display: flex;
|
||||
align-items: stretch;
|
||||
justify-content: stretch;
|
||||
|
||||
> button {
|
||||
flex: 1 1 auto;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
|
||||
svg.scaleX-90 {
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
|
||||
svg.scaleX-180 {
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
|
||||
svg.scaleX-270 {
|
||||
transform: rotate(270deg);
|
||||
}
|
||||
}
|
||||
}
|
||||
184
packages/amis-editor-core/scss/control/_formItem-control.scss
Normal file
184
packages/amis-editor-core/scss/control/_formItem-control.scss
Normal file
@@ -0,0 +1,184 @@
|
||||
/* 表单项配置面板 */
|
||||
.ae-formItemControl {
|
||||
&-label-tip {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
div[data-role='form-item'] {
|
||||
&.ae-ExtendMore {
|
||||
> label {
|
||||
flex: 0;
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
> label {
|
||||
line-height: 32px;
|
||||
margin: 0;
|
||||
padding-top: 0;
|
||||
|
||||
> span {
|
||||
display: inline;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ae-InputRangeValue-input-group {
|
||||
&-delimiter {
|
||||
border: none;
|
||||
padding-left: 5px;
|
||||
padding-right: 5px;
|
||||
line-height: 30px;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-sub-content {
|
||||
@include extend-more();
|
||||
margin-bottom: var(--Form-item-gap);
|
||||
|
||||
&.is-bottom {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* 面板 Collapse 样式覆写,为了提高优先级,用顶层类包裹 */
|
||||
.ae-Outline-panel,
|
||||
.ae-Settings-content {
|
||||
.ae-formItemControl {
|
||||
& > div:last-child {
|
||||
.ae-formItemControl-header {
|
||||
border-bottom: 1px solid #e5e5e5;
|
||||
}
|
||||
|
||||
&.is-active {
|
||||
.ae-formItemControl-header {
|
||||
border-bottom: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
div.ae-formItemControl-header.ae-Collapse-header {
|
||||
width: 100%;
|
||||
padding: #{px2rem(6px)} #{px2rem(12px)};
|
||||
justify-content: space-between;
|
||||
align-items: unset;
|
||||
border-top: 1px solid #e5e5e5;
|
||||
background: #f2f2f4;
|
||||
border-radius: 0 !important;
|
||||
@include collapse-header-text();
|
||||
|
||||
i {
|
||||
transform-origin: px2rem(7px) px2rem(5px);
|
||||
margin-top: px2rem(5px);
|
||||
transition: transform 0.1s linear;
|
||||
}
|
||||
}
|
||||
|
||||
&-body {
|
||||
--Form-item-gap: 12px;
|
||||
|
||||
padding: var(--gap-base);
|
||||
|
||||
> div:first-child {
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
.fix-icon-picker-overflow {
|
||||
input {
|
||||
width: 0;
|
||||
}
|
||||
a {
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
left: -10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* 状态配置控件 */
|
||||
.ae-StatusControl {
|
||||
position: relative;
|
||||
&-switch {
|
||||
position: absolute;
|
||||
top: px2rem(-24px);
|
||||
right: 0;
|
||||
}
|
||||
|
||||
&-content {
|
||||
padding-top: px2rem(12px);
|
||||
> div {
|
||||
@include extend-more();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* 代码块 */
|
||||
.ae-Code {
|
||||
background: #ebf5ff;
|
||||
color: #008dcd;
|
||||
padding: #{px2rem(3px)} #{$Editor-borderRadius};
|
||||
border-radius: #{px2rem(3px)};
|
||||
}
|
||||
|
||||
.ae-ExtendMore {
|
||||
@include extend-more();
|
||||
}
|
||||
|
||||
/* 加强状态按钮,后续添加在AMIS中 */
|
||||
.ae-Button--enhance {
|
||||
color: #{$Editor-theme-color};
|
||||
border: 1px solid #{$Editor-theme-color};
|
||||
|
||||
&:hover,
|
||||
&:focus {
|
||||
color: #4f86f4 !important;
|
||||
border-color: #4f86f4 !important;
|
||||
}
|
||||
}
|
||||
|
||||
/* combo 组件样式调整, 后续amis中combo支持新增button自定义就可免去样式覆盖了*/
|
||||
.ae-Combo-items {
|
||||
@include extend-more();
|
||||
margin-top: px2rem(8px);
|
||||
> div {
|
||||
background: inherit;
|
||||
|
||||
+ div {
|
||||
margin-top: px2rem(12px) !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* 设置面板 combo 多行模式样式调整 */
|
||||
.cxd-Combo--ver:not(.cxd-Combo--noBorder) > .ae-Combo-items {
|
||||
margin: px2rem(8px) 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.cxd-Combo--ver:not(.cxd-Combo--noBorder) > .ae-Combo-items > .cxd-Combo-item {
|
||||
margin: 0;
|
||||
border: none;
|
||||
|
||||
&:hover {
|
||||
border: none !important;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-Combo-items + div {
|
||||
padding-left: 0px !important;
|
||||
margin-bottom: px2rem(12px);
|
||||
> button,
|
||||
> button:hover {
|
||||
color: #528eff !important;
|
||||
background: #ffffff !important;
|
||||
border-color: #528eff !important;
|
||||
width: 100%;
|
||||
height: px2rem(32px);
|
||||
}
|
||||
}
|
||||
|
||||
.form-item-gap {
|
||||
margin-bottom: var(--Form-item-gap);
|
||||
}
|
||||
216
packages/amis-editor-core/scss/control/_formula-control.scss
Normal file
216
packages/amis-editor-core/scss/control/_formula-control.scss
Normal file
@@ -0,0 +1,216 @@
|
||||
div.ae-editor-FormulaControl {
|
||||
position: relative;
|
||||
@include flexBox();
|
||||
align-items: stretch;
|
||||
max-width: 100%;
|
||||
}
|
||||
.ae-editor-FormulaControl {
|
||||
& > &-buttonWrapper {
|
||||
height: auto;
|
||||
}
|
||||
& > &-buttonWrapper > &-button {
|
||||
height: 100%;
|
||||
background-color: #f7f7f9;
|
||||
padding: 4px 8px;
|
||||
border-radius: 0 var(--button-size-sm-top-left-border-radius)
|
||||
var(--button-size-sm-bottom-right-border-radius) 0;
|
||||
border-left: 0;
|
||||
&:not(:disabled):not(.is-disabled):hover {
|
||||
border-color: #e6f0ff;
|
||||
background-color: #e6f0ff;
|
||||
border-left-width: 0;
|
||||
}
|
||||
&:not(:disabled):not(.is-disabled):active {
|
||||
border-left-width: 1;
|
||||
transition: var(--Button-transition);
|
||||
}
|
||||
}
|
||||
|
||||
& &-input {
|
||||
flex: 1;
|
||||
height: 32px;
|
||||
border-radius: var(--input-default-default-top-left-border-radius) 0 0
|
||||
var(--input-default-default-bottom-left-border-radius);
|
||||
max-width: calc(100% - 29px); // 避免表达式内容太长撑开面板
|
||||
|
||||
&.is-clearable {
|
||||
padding-right: 30px; // 避免间隙过大
|
||||
}
|
||||
|
||||
svg {
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
}
|
||||
}
|
||||
|
||||
&-select-style {
|
||||
> div {
|
||||
border-radius: var(--Form-select-borderRadius) 0 0
|
||||
var(--Form-select-borderRadius);
|
||||
}
|
||||
}
|
||||
|
||||
// 当有提示时底部增加点外边距
|
||||
&.is-has-tooltip {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
// 底部提示
|
||||
.desc-msg {
|
||||
visibility: hidden;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
transform-origin: left top;
|
||||
transform: translateY(90%) scale(0.8);
|
||||
font-size: 10px;
|
||||
max-width: 100%;
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
|
||||
&.info-msg {
|
||||
color: $editor-active-color; // $default-icon-color;
|
||||
}
|
||||
|
||||
&.error-msg {
|
||||
visibility: visible; // 错误类提示 固定展示
|
||||
color: #f33e3e;
|
||||
transform: translateY(90%) scale(0.9);
|
||||
}
|
||||
}
|
||||
|
||||
&:hover .desc-msg {
|
||||
visibility: visible; // 普通提示类信息,hover时展示
|
||||
}
|
||||
|
||||
&-custom-renderer {
|
||||
width: calc(100% - 35px);
|
||||
flex: 1 1 auto;
|
||||
border: none;
|
||||
padding: 0;
|
||||
> div {
|
||||
min-height: 32px;
|
||||
}
|
||||
> div,
|
||||
&:not(.border-wrapper) > div > div {
|
||||
border-radius: var(--input-default-default-top-left-border-radius) 0 0
|
||||
var(--input-default-default-bottom-left-border-radius);
|
||||
}
|
||||
|
||||
&.border-wrapper {
|
||||
padding: 2px 4px;
|
||||
border: 1px dashed #e8e9eb;
|
||||
}
|
||||
}
|
||||
|
||||
&-ResultBox {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
border: 1px solid var(--Form-input-borderColor);
|
||||
border-radius: var(--input-default-default-top-left-border-radius) 0 0
|
||||
var(--input-default-default-bottom-left-border-radius);
|
||||
background: var(--Form-input-bg);
|
||||
font-size: var(--Form-input-fontSize);
|
||||
padding: 0 8px;
|
||||
|
||||
&::placeholder {
|
||||
color: var(--Form-input-placeholderColor);
|
||||
}
|
||||
|
||||
&:hover {
|
||||
border-color: var(--Form-input-onHover-borderColor);
|
||||
}
|
||||
|
||||
&-wrapper {
|
||||
flex: 1 1;
|
||||
width: 0px; // 通过flex-grow 展开宽度
|
||||
border-radius: var(--Form-input-borderRadius);
|
||||
}
|
||||
|
||||
&-editor {
|
||||
& > .CodeMirror {
|
||||
height: 100%;
|
||||
color: var(--Form-input-color);
|
||||
font-family: inherit;
|
||||
|
||||
// span[class^='cm-'] {
|
||||
// color: var(--input-default-default-color);
|
||||
// }
|
||||
|
||||
// 解决上下 pre标签中表达式浮层遮挡问题
|
||||
.CodeMirror-measure + div {
|
||||
z-index: inherit !important;
|
||||
}
|
||||
pre.CodeMirror-line,
|
||||
.CodeMirror pre.CodeMirror-line-like {
|
||||
z-index: initial;
|
||||
}
|
||||
|
||||
.CodeMirror-sizer {
|
||||
min-height: 30px !important;
|
||||
}
|
||||
|
||||
.CodeMirror-hscrollbar {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.CodeMirror-scrollbar-filler {
|
||||
display: none !important;
|
||||
}
|
||||
.CodeMirror-vscrollbar {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.CodeMirror-scroll {
|
||||
overflow: hidden !important;
|
||||
}
|
||||
|
||||
.CodeMirror-lines {
|
||||
line-height: 20px;
|
||||
padding: 5px 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.cm-expression {
|
||||
background: #007bff;
|
||||
padding: 0px 5px;
|
||||
margin: 0 1px;
|
||||
color: #fff;
|
||||
font-size: 12px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
.input-clear-icon {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
right: 8px;
|
||||
margin: auto;
|
||||
height: 14px;
|
||||
fill: var(--Form-input-clearBtn-color);
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
fill: var(--Form-input-clearBtn-color-onHover);
|
||||
}
|
||||
}
|
||||
|
||||
&-icon {
|
||||
top: 0 !important;
|
||||
font-size: #{px2rem(14px)};
|
||||
|
||||
&:not(:last-child) {
|
||||
margin-right: var(--fontSizeSm);
|
||||
}
|
||||
|
||||
&.is-filled {
|
||||
fill: var(--primary);
|
||||
color: var(--primary);
|
||||
}
|
||||
}
|
||||
}
|
||||
63
packages/amis-editor-core/scss/control/_global-var.scss
Normal file
63
packages/amis-editor-core/scss/control/_global-var.scss
Normal file
@@ -0,0 +1,63 @@
|
||||
.ae-GlobalVarPanel {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
|
||||
> .panel-header {
|
||||
flex-shrink: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-GlobalVarManager {
|
||||
border-top: 1px solid #e8e9eb;
|
||||
padding: 12px;
|
||||
flex: 1;
|
||||
min-height: 0;
|
||||
overflow: auto;
|
||||
@include minScrollBar();
|
||||
|
||||
& > ul {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
&-empty {
|
||||
color: #b4b6ba;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
&-AddBtn {
|
||||
margin-top: 12px;
|
||||
// position: sticky;
|
||||
// bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-GlobalVarItem {
|
||||
padding: 0;
|
||||
display: flex;
|
||||
height: 34px;
|
||||
line-height: 32px;
|
||||
margin: 0 0 12px;
|
||||
|
||||
&-info {
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
border-radius: 4px;
|
||||
padding: 0 10px;
|
||||
border: 1px solid #e8e9eb;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
&-actions {
|
||||
width: 64px;
|
||||
flex-shrink: 0;
|
||||
|
||||
& > button {
|
||||
border: 0 !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
35
packages/amis-editor-core/scss/control/_go-config.scss
Normal file
35
packages/amis-editor-core/scss/control/_go-config.scss
Normal file
@@ -0,0 +1,35 @@
|
||||
.ae-GoConfig {
|
||||
height: 32px;
|
||||
line-height: 32px;
|
||||
position: relative;
|
||||
background-color: #fff;
|
||||
text-align: center;
|
||||
font-size: $Editor-right-panel-font-size;
|
||||
border: 1px solid #e6e6e8;
|
||||
border-radius: $Editor-borderRadius;
|
||||
|
||||
&-trigger {
|
||||
display: none;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
cursor: pointer;
|
||||
color: #fff;
|
||||
background-color: rgba($color: #000000, $alpha: 0.55);
|
||||
}
|
||||
|
||||
&:hover {
|
||||
border: none;
|
||||
|
||||
&.ae-FeatureControlItem-go {
|
||||
color: transparent;
|
||||
}
|
||||
|
||||
.ae-GoConfig-trigger {
|
||||
display: block;
|
||||
border-radius: $Editor-borderRadius;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
.icon-ButtonList {
|
||||
button {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 42px;
|
||||
background-color: #fff !important;
|
||||
box-sizing: border-box;
|
||||
|
||||
svg {
|
||||
margin: 0 !important;
|
||||
padding: 0 !important;
|
||||
width: 20px;
|
||||
min-height: 20px;
|
||||
}
|
||||
|
||||
&.is-active {
|
||||
svg {
|
||||
fill: $Editor-theme-color;
|
||||
color: $Editor-theme-color;
|
||||
}
|
||||
i {
|
||||
color: $Editor-theme-color;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
13
packages/amis-editor-core/scss/control/_inpupt-file.scss
Normal file
13
packages/amis-editor-core/scss/control/_inpupt-file.scss
Normal file
@@ -0,0 +1,13 @@
|
||||
.inputFile-apiControl {
|
||||
margin-top: 30px;
|
||||
|
||||
.ApiControl {
|
||||
margin-bottom: 0;
|
||||
|
||||
&-header {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: -25px;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
.ae-KeyValMapControl-wrapper {
|
||||
.ae-KeyValMapControlItem-Main {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.ae-KeyValMapControlItem-flex {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.ae-KeyValMapControlItem-input {
|
||||
flex: 1;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
.ae-ExtendMore {
|
||||
position: relative;
|
||||
|
||||
.cxd-Container-body {
|
||||
margin-top: 20px;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-KeyValMapControlItem-closeBtn {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
font-size: 18px;
|
||||
color: #151b26;
|
||||
padding-right: 0.625rem;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.ae-KeyValMapControlItem-EditLabel {
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.ae-KeyValMapControl-footer > * {
|
||||
width: calc(50% - 0.375rem);
|
||||
}
|
||||
|
||||
.ae-KeyValMapControl-footer > *:first-child {
|
||||
margin-right: 0.75rem;
|
||||
}
|
||||
}
|
||||
184
packages/amis-editor-core/scss/control/_nav-control.scss
Normal file
184
packages/amis-editor-core/scss/control/_nav-control.scss
Normal file
@@ -0,0 +1,184 @@
|
||||
.ae-NavControl {
|
||||
&-header {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
height: #{px2rem(24px)};
|
||||
margin-bottom: #{px2rem(12px)};
|
||||
}
|
||||
|
||||
&-content {
|
||||
@include flexBox(column, flex-start);
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
.ae-OptionControlItem {
|
||||
display: block;
|
||||
width: 100%;
|
||||
border: 1px dashed #999;
|
||||
padding: 15px;
|
||||
margin-bottom: 10px;
|
||||
position: relative;
|
||||
|
||||
.ae-closeBtn {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
font-size: 18px;
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.ae-navControlLinks {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
height: 40px;
|
||||
|
||||
input {
|
||||
width: 120px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-placeholder {
|
||||
display: none;
|
||||
color: #999;
|
||||
line-height: #{px2rem(24px)};
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
width: 100%;
|
||||
padding: #{px2rem(10px)};
|
||||
}
|
||||
|
||||
&-footer {
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
&-footer > * {
|
||||
width: calc(50% - #{px2rem(6px)});
|
||||
|
||||
&:first-child {
|
||||
margin-right: px2rem(12px);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.nav-mode-gif {
|
||||
width: 160px;
|
||||
height: 120px;
|
||||
background: url('../static/nav-mode.png');
|
||||
background-repeat: no-repeat;
|
||||
background-size: 100%;
|
||||
margin: 10px auto 0;
|
||||
}
|
||||
|
||||
.ae-BadgeControl {
|
||||
.cxd-Form-groupColumn:nth-child(1) {
|
||||
padding-right: 4px;
|
||||
}
|
||||
.cxd-Form-groupColumn:nth-child(2) {
|
||||
padding-left: 4px;
|
||||
}
|
||||
.cxd-TextControl.is-focused > .cxd-TextControl-input {
|
||||
border-top-left-radius: 0;
|
||||
border-bottom-left-radius: 0;
|
||||
padding-left: 4px;
|
||||
}
|
||||
.cxd-TextControl-addOn:first-child {
|
||||
border-left-width: 0.0625rem;
|
||||
}
|
||||
.cxd-TextControl-input {
|
||||
padding: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
// 自定义数据样式
|
||||
.ae-NavControl-header {
|
||||
display: flex;
|
||||
flex-flow: row nowrap;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
height: 1.5rem;
|
||||
margin-bottom: 0.75rem;
|
||||
}
|
||||
.ae-NavControl-wrapper {
|
||||
.nav-links {
|
||||
&-parent {
|
||||
width: 100%;
|
||||
}
|
||||
&-item {
|
||||
height: 32px;
|
||||
margin-bottom: 8px;
|
||||
padding: 0 10px 0 8px;
|
||||
border-radius: 2px;
|
||||
background-color: #f7f7f9;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
font-family: PingFangSC-Regular;
|
||||
font-size: 12px;
|
||||
color: #151b26;
|
||||
|
||||
&-icon {
|
||||
margin: 0 -2px 0 8px;
|
||||
color: #151b26;
|
||||
}
|
||||
&-dragBar {
|
||||
color: #151b26;
|
||||
|
||||
&:hover {
|
||||
color: #2468f2;
|
||||
}
|
||||
}
|
||||
|
||||
&-label {
|
||||
flex: 1;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
color: #151b26;
|
||||
margin-left: 8px;
|
||||
}
|
||||
|
||||
&-actions {
|
||||
width: auto;
|
||||
|
||||
.icon {
|
||||
color: #84868c;
|
||||
font-size: 14px;
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
color: #2468f2;
|
||||
}
|
||||
}
|
||||
.icon-edit {
|
||||
margin-left: 12px;
|
||||
}
|
||||
.icon-delete {
|
||||
margin-left: 13px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-children {
|
||||
margin-left: 24px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ae-NavControl-footer {
|
||||
button {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.ae-NavControl-dialog {
|
||||
.cxd-IconPickerControl-valueWrap {
|
||||
display: flex;
|
||||
}
|
||||
}
|
||||
179
packages/amis-editor-core/scss/control/_option-control.scss
Normal file
179
packages/amis-editor-core/scss/control/_option-control.scss
Normal file
@@ -0,0 +1,179 @@
|
||||
.ae-OptionControl {
|
||||
&-header {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
height: #{px2rem(24px)};
|
||||
margin-bottom: #{px2rem(12px)};
|
||||
}
|
||||
|
||||
&-content {
|
||||
@include flexBox(column, flex-start);
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
.ae-OptionControlItem {
|
||||
display: block;
|
||||
width: 100%;
|
||||
|
||||
&-Main {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
background: #fff;
|
||||
padding-bottom: px2rem(12px);
|
||||
}
|
||||
|
||||
&--dragging {
|
||||
height: 0 !important;
|
||||
padding: 0;
|
||||
border-top: 2px solid var(--primary);
|
||||
overflow: hidden;
|
||||
background: #e9effd;
|
||||
}
|
||||
|
||||
&-dragBar {
|
||||
display: inline-flex;
|
||||
margin-left: 0;
|
||||
margin-right: var(--gap-sm);
|
||||
cursor: move;
|
||||
color: #8c8c8c;
|
||||
}
|
||||
|
||||
&-checkbox {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
line-height: #{px2rem(24px)};
|
||||
|
||||
span {
|
||||
color: #080e1a;
|
||||
margin-left: #{px2rem(12px)};
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
max-width: 145px;
|
||||
}
|
||||
}
|
||||
|
||||
&-input {
|
||||
flex: 1;
|
||||
margin: 0;
|
||||
margin-right: #{px2rem(12px)};
|
||||
|
||||
input {
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
}
|
||||
|
||||
&-dropdown i {
|
||||
margin-right: 0px;
|
||||
}
|
||||
|
||||
&-EditLabel {
|
||||
flex: 0 0 2.25rem;
|
||||
padding-right: 0;
|
||||
}
|
||||
|
||||
&-EditValue {
|
||||
padding-left: 0;
|
||||
}
|
||||
|
||||
&-closeBtn {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
font-size: 18px;
|
||||
color: #{$Editor-right-panel-color};
|
||||
padding-right: px2rem(10px);
|
||||
|
||||
&:hover {
|
||||
color: #{$Editor-theme};
|
||||
}
|
||||
}
|
||||
|
||||
.ae-ExtendMore {
|
||||
padding-right: px2rem(30px);
|
||||
}
|
||||
&-action-delete {
|
||||
color: #d4d6d9;
|
||||
padding: 0px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-placeholder {
|
||||
display: none;
|
||||
color: #999;
|
||||
line-height: #{px2rem(24px)};
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
width: 100%;
|
||||
padding: #{px2rem(10px)};
|
||||
}
|
||||
|
||||
&-footer > * {
|
||||
// @include flexBox(row, flex-end);
|
||||
// // background: #f2f7f3;
|
||||
// padding: #{px2rem(5px)};
|
||||
// border-bottom-right-radius: $Editor-borderRadius;
|
||||
// border-bottom-left-radius: $Editor-borderRadius;
|
||||
// border-top: 1px solid #f2f7f3;
|
||||
// box-shadow: 0 0 5px rgb(8 14 26 / 6%);
|
||||
// clip-path: inset(-5px 0px 0px 0px);
|
||||
|
||||
width: calc(50% - #{px2rem(6px)});
|
||||
|
||||
&:first-child {
|
||||
margin-right: px2rem(12px);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ae-OptionControl-PopoverEdit {
|
||||
@include flexBox(column, space-between, flex-start);
|
||||
padding: #{px2rem(15px)} #{px2rem(20px)};
|
||||
border: none;
|
||||
width: 300px;
|
||||
|
||||
header {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
height: #{px2rem(24px)};
|
||||
margin-bottom: #{px2rem(10px)};
|
||||
|
||||
.ae-OptionControl-PopoverEdit-title {
|
||||
opacity: 0.95;
|
||||
font-size: var(--fontSizeMd);
|
||||
color: #080e1a;
|
||||
line-height: #{px2rem(24px)};
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.ae-OptionControl-PopoverEdit-close {
|
||||
float: right;
|
||||
color: var(--text--muted-color);
|
||||
line-height: inherit;
|
||||
text-decoration: none;
|
||||
vertical-align: middle;
|
||||
|
||||
svg {
|
||||
width: #{px2rem(12px)};
|
||||
height: #{px2rem(12px)};
|
||||
fill: var(--text--muted-color);
|
||||
}
|
||||
|
||||
&:not(.is-disabled) {
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
text-decoration: none;
|
||||
color: var(--text-color);
|
||||
|
||||
svg {
|
||||
fill: var(--text-color);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
75
packages/amis-editor-core/scss/control/_status.scss
Normal file
75
packages/amis-editor-core/scss/control/_status.scss
Normal file
@@ -0,0 +1,75 @@
|
||||
// 状态组件页面设计器
|
||||
.ae-Status-label {
|
||||
& > span {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
&-tip-icon {
|
||||
margin-left: 0.25rem;
|
||||
line-height: 14px;
|
||||
display: inline-block;
|
||||
cursor: pointer;
|
||||
|
||||
.icon {
|
||||
width: 14px;
|
||||
height: 14px;
|
||||
fill: #84868c;
|
||||
}
|
||||
}
|
||||
}
|
||||
.ae-Status-default-icon {
|
||||
&-tooltip {
|
||||
max-width: none;
|
||||
}
|
||||
&-tip {
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
.ae-Status-control {
|
||||
.cxd-Combo-itemInner {
|
||||
.cxd-Form-row {
|
||||
margin-right: 0;
|
||||
.cxd-Form-col {
|
||||
padding-left: 2px;
|
||||
padding-right: 2px;
|
||||
&:first-child {
|
||||
flex-grow: 0;
|
||||
min-width: 55px;
|
||||
// 新版图标选择 占位缩小处理
|
||||
.cxd-IconSelectControl {
|
||||
&-input {
|
||||
padding-left: 6px;
|
||||
}
|
||||
&-clear {
|
||||
right: 4px;
|
||||
}
|
||||
}
|
||||
// iconfont 占位缩小处理
|
||||
.cxd-IconPickerControl {
|
||||
&-value {
|
||||
width: 12px;
|
||||
overflow: hidden;
|
||||
}
|
||||
&-clear {
|
||||
position: absolute;
|
||||
right: -5px;
|
||||
top: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
&:last-child {
|
||||
flex-grow: 0;
|
||||
}
|
||||
.cxd-IconSelectControl-input-icon-id {
|
||||
display: none;
|
||||
}
|
||||
.Theme-ColorPicker-label-out {
|
||||
width: 1.35rem;
|
||||
height: 1.35rem;
|
||||
position: relative;
|
||||
top: 0.2rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
124
packages/amis-editor-core/scss/control/_switch-more-control.scss
Normal file
124
packages/amis-editor-core/scss/control/_switch-more-control.scss
Normal file
@@ -0,0 +1,124 @@
|
||||
.ae-SwitchMore {
|
||||
flex-grow: 1;
|
||||
|
||||
&-switch {
|
||||
@include flexBox();
|
||||
justify-content: flex-end;
|
||||
height: px2rem(30px);
|
||||
|
||||
div {
|
||||
@include flexBox(row, flex-end);
|
||||
background-color: #fff !important;
|
||||
flex: 1;
|
||||
hr {
|
||||
display: inline-block;
|
||||
border: 0;
|
||||
margin: 0;
|
||||
border-left: 1px solid #e6e6e8;
|
||||
height: #{px2rem(16px)};
|
||||
vertical-align: middle;
|
||||
margin: 0 #{px2rem(12px)};
|
||||
}
|
||||
|
||||
svg.icon {
|
||||
margin-bottom: #{px2rem(-2px)};
|
||||
}
|
||||
|
||||
.ae-SwitchMore-icon {
|
||||
fill: var(--primary);
|
||||
|
||||
path {
|
||||
fill: var(--primary);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.cxd-DropDown,
|
||||
.cxd-DropDown > .cxd-Button {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.action-btn {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.open-btn {
|
||||
transition: transform var(--animation-duration);
|
||||
color: #b8babf;
|
||||
|
||||
&.opening {
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
}
|
||||
|
||||
&-popover {
|
||||
padding: #{px2rem(12px)};
|
||||
border: none;
|
||||
min-width: px2rem(300px);
|
||||
max-width: px2rem(640px);
|
||||
|
||||
header {
|
||||
@include flexBox(row, flex-end);
|
||||
width: 100%;
|
||||
height: #{px2rem(24px)};
|
||||
margin-bottom: #{px2rem(10px)};
|
||||
}
|
||||
|
||||
.ae-SwitchMore-title {
|
||||
opacity: 0.95;
|
||||
font-size: var(--fontSizeMd);
|
||||
color: #080e1a;
|
||||
line-height: #{px2rem(24px)};
|
||||
font-weight: bold;
|
||||
width: 100%;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.ae-SwitchMore-close {
|
||||
float: right;
|
||||
color: var(--text--muted-color);
|
||||
line-height: inherit;
|
||||
text-decoration: none;
|
||||
vertical-align: middle;
|
||||
|
||||
svg {
|
||||
width: #{px2rem(12px)};
|
||||
height: #{px2rem(12px)};
|
||||
fill: var(--text--muted-color);
|
||||
}
|
||||
|
||||
&:not(.is-disabled) {
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
text-decoration: none;
|
||||
color: var(--text-color);
|
||||
|
||||
svg {
|
||||
fill: var(--text-color);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-extend {
|
||||
position: relative;
|
||||
|
||||
.ae-SwitchMore {
|
||||
&-switch {
|
||||
position: absolute;
|
||||
top: px2rem(-32px);
|
||||
right: 0;
|
||||
}
|
||||
|
||||
&-content {
|
||||
padding-top: px2rem(12px);
|
||||
& > div {
|
||||
@include extend-more();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
/**
|
||||
* @file table-column-width-control.scss
|
||||
* @desc 表格列宽控件
|
||||
*/
|
||||
|
||||
.ae-columnWidthControl {
|
||||
&-header {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
align-items: baseline;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,229 @@
|
||||
.ae-TextareaFormulaControl {
|
||||
position: relative;
|
||||
&-input {
|
||||
textarea {
|
||||
resize: none;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-TextareaResultBox {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: block;
|
||||
border: 1px solid var(--Form-input-borderColor);
|
||||
border-radius: var(--Form-input-borderRadius);
|
||||
background: var(--Form-input-bg);
|
||||
font-size: var(--Form-input-fontSize);
|
||||
padding-bottom: 26px;
|
||||
&::placeholder {
|
||||
color: var(--Form-input-placeholderColor);
|
||||
}
|
||||
|
||||
&:hover {
|
||||
border-color: var(--Form-input-onHover-borderColor);
|
||||
}
|
||||
|
||||
&-editor {
|
||||
height: 100%;
|
||||
border-radius: var(--Form-input-borderRadius);
|
||||
overflow: auto;
|
||||
padding-left: 8px;
|
||||
|
||||
& > .CodeMirror {
|
||||
height: 100%;
|
||||
font-family: inherit;
|
||||
// span[class^='cm-'] {
|
||||
// color: var(--input-default-default-color);
|
||||
// }
|
||||
|
||||
// 解决上下 pre标签中表达式浮层遮挡问题
|
||||
.CodeMirror-measure + div {
|
||||
z-index: inherit !important;
|
||||
}
|
||||
pre.CodeMirror-line,
|
||||
.CodeMirror pre.CodeMirror-line-like {
|
||||
z-index: initial;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-placeholder {
|
||||
position: absolute;
|
||||
line-height: 28px;
|
||||
top: 0;
|
||||
left: 13px;
|
||||
font-size: 12px;
|
||||
color: var(--text--muted-color);
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
&-footer {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
background: #f7f7f9;
|
||||
bottom: 0px;
|
||||
height: 26px;
|
||||
margin: 0;
|
||||
border-radius: 0 0 4px 4px;
|
||||
list-style: none;
|
||||
display: flex;
|
||||
flex-direction: row-reverse;
|
||||
align-items: center;
|
||||
> li {
|
||||
margin-right: 10px;
|
||||
cursor: pointer;
|
||||
|
||||
&.is-loading {
|
||||
display: flex;
|
||||
cursor: unset;
|
||||
}
|
||||
}
|
||||
&--fullscreen {
|
||||
> a {
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
&-fxIcon {
|
||||
> a {
|
||||
font-size: 14px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-overlay {
|
||||
position: absolute;
|
||||
top: 1px;
|
||||
left: 1px;
|
||||
width: calc(100% - 4px);
|
||||
height: calc(100% - 4px);
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
|
||||
&.is-fullscreen {
|
||||
margin: 0 !important;
|
||||
position: fixed !important;
|
||||
top: 0;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
z-index: 2147483630 !important;
|
||||
width: auto !important;
|
||||
height: auto !important;
|
||||
.ae-TextareaResultBox {
|
||||
height: 100% !important;
|
||||
&-editor {
|
||||
& > .CodeMirror {
|
||||
height: 100%;
|
||||
padding: 10px 10px 48px;
|
||||
.CodeMirror-vscrollbar {
|
||||
margin-bottom: 48px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-footer {
|
||||
height: 48px;
|
||||
> li {
|
||||
margin-right: 20px;
|
||||
}
|
||||
&-fullscreen {
|
||||
> a {
|
||||
font-size: 18px;
|
||||
}
|
||||
}
|
||||
&-fxIcon {
|
||||
> a {
|
||||
font-size: 20px;
|
||||
}
|
||||
}
|
||||
}
|
||||
&-placeholder {
|
||||
padding: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.cm-expression {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
border-radius: 4px;
|
||||
padding: 0 5px;
|
||||
margin: 0 1px 1px;
|
||||
background: var(--button-primary-default-bg-color);
|
||||
|
||||
&-text {
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
color: #fff !important;
|
||||
cursor: pointer;
|
||||
max-width: 80px;
|
||||
min-width: 10px;
|
||||
min-height: 18px;
|
||||
overflow-x: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
vertical-align: middle;
|
||||
line-height: 16px;
|
||||
|
||||
&:hover {
|
||||
background: var(--button-primary-hover-bg-color);
|
||||
& ~ .cm-expression-popover {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-close {
|
||||
font-size: 12px;
|
||||
color: white;
|
||||
cursor: pointer;
|
||||
margin-left: 4px;
|
||||
}
|
||||
|
||||
&-popover {
|
||||
position: absolute;
|
||||
display: none;
|
||||
left: 0;
|
||||
bottom: -30px;
|
||||
transform: translate(calc(24px - 50%));
|
||||
font-size: 12px;
|
||||
width: max-content;
|
||||
color: #fff;
|
||||
border-radius: 4px;
|
||||
padding: 2px 8px;
|
||||
background: var(--Tooltip-bg--dark);
|
||||
border: none;
|
||||
box-shadow: var(--Tooltip-boxShadow--dark);
|
||||
z-index: 10;
|
||||
|
||||
&-arrow {
|
||||
position: absolute;
|
||||
display: block;
|
||||
width: var(--Tooltip-arrow-width);
|
||||
height: var(--Tooltip-arrow-height);
|
||||
margin-left: calc(var(--Tooltip-arrow-width) * -1 / 2);
|
||||
left: 50%;
|
||||
top: calc(var(--Tooltip-arrow-height) * -1);
|
||||
|
||||
&::before,
|
||||
&::after {
|
||||
position: absolute;
|
||||
display: block;
|
||||
content: '';
|
||||
border-color: transparent;
|
||||
border-style: solid;
|
||||
border-width: 0 calc(var(--Tooltip-arrow-width) / 2)
|
||||
var(--Tooltip-arrow-height) calc(var(--Tooltip-arrow-width) / 2);
|
||||
}
|
||||
&::before {
|
||||
border-width: 0;
|
||||
}
|
||||
&::after {
|
||||
border-bottom-color: var(--Tooltip-arrow-color--dark);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,83 @@
|
||||
.ae-TimelineItemControl {
|
||||
&-header {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
height: #{px2rem(24px)};
|
||||
margin-bottom: #{px2rem(12px)};
|
||||
}
|
||||
|
||||
&-content {
|
||||
@include flexBox(column, flex-start);
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
.ae-TimelineItemControlItem {
|
||||
display: block;
|
||||
width: 100%;
|
||||
|
||||
&-input-title {
|
||||
flex: 1;
|
||||
margin-left: #{px2rem(20px)};
|
||||
margin-right: #{px2rem(44px)};
|
||||
input {
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
}
|
||||
&-input {
|
||||
flex: 1;
|
||||
margin: 0;
|
||||
margin-right: #{px2rem(12px)};
|
||||
}
|
||||
|
||||
&-Main {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
background: #fff;
|
||||
padding-bottom: px2rem(12px);
|
||||
}
|
||||
|
||||
&--dragging {
|
||||
height: 0 !important;
|
||||
padding: 0;
|
||||
border-top: 2px solid var(--primary);
|
||||
overflow: hidden;
|
||||
background: #e9effd;
|
||||
}
|
||||
|
||||
&-dragBar {
|
||||
display: inline-flex;
|
||||
margin-left: 0;
|
||||
margin-right: var(--gap-sm);
|
||||
cursor: move;
|
||||
color: #8c8c8c;
|
||||
}
|
||||
|
||||
&-dropdown i {
|
||||
margin-right: 0px;
|
||||
}
|
||||
}
|
||||
|
||||
.ae-TimelineItemControlItem-inputDate {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
&-border {
|
||||
background-color: #e5e5e5;
|
||||
width: 100%;
|
||||
height: 1px;
|
||||
margin-top: 12px;
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
|
||||
&-footer > * {
|
||||
width: calc(50% - #{px2rem(6px)});
|
||||
|
||||
&:first-child {
|
||||
margin-right: px2rem(12px);
|
||||
}
|
||||
}
|
||||
}
|
||||
160
packages/amis-editor-core/scss/control/_tpl-formula-control.scss
Normal file
160
packages/amis-editor-core/scss/control/_tpl-formula-control.scss
Normal file
@@ -0,0 +1,160 @@
|
||||
.ae-TplFormulaControl {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
height: var(--input-size-default-height);
|
||||
|
||||
.ae-TplResultBox {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
border: 1px solid var(--Form-input-borderColor);
|
||||
border-radius: var(--input-default-default-top-left-border-radius) 0 0
|
||||
var(--input-default-default-bottom-left-border-radius);
|
||||
background: var(--Form-input-bg);
|
||||
font-size: var(--Form-input-fontSize);
|
||||
padding: 0 8px;
|
||||
|
||||
.input-clear-icon {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
right: 8px;
|
||||
margin: auto;
|
||||
height: 14px;
|
||||
fill: var(--Form-input-clearBtn-color);
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
fill: var(--Form-input-clearBtn-color-onHover);
|
||||
}
|
||||
}
|
||||
|
||||
&::placeholder {
|
||||
color: var(--Form-input-placeholderColor);
|
||||
}
|
||||
|
||||
&:hover {
|
||||
border-color: var(--Form-input-onHover-borderColor);
|
||||
}
|
||||
|
||||
&-editor {
|
||||
flex: 1 1;
|
||||
width: 0px; // 通过flex-grow 展开宽度
|
||||
border-radius: var(--Form-input-borderRadius);
|
||||
& > .CodeMirror {
|
||||
height: 100%;
|
||||
color: var(--Form-input-color);
|
||||
font-family: inherit;
|
||||
|
||||
// span[class^='cm-'] {
|
||||
// color: var(--input-default-default-color);
|
||||
// }
|
||||
|
||||
// 解决上下 pre标签中表达式浮层遮挡问题
|
||||
.CodeMirror-measure + div {
|
||||
z-index: inherit !important;
|
||||
}
|
||||
pre.CodeMirror-line,
|
||||
.CodeMirror pre.CodeMirror-line-like {
|
||||
z-index: initial;
|
||||
}
|
||||
|
||||
.CodeMirror-sizer {
|
||||
min-height: 30px !important;
|
||||
}
|
||||
|
||||
.CodeMirror-hscrollbar {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.CodeMirror-scrollbar-filler {
|
||||
display: none !important;
|
||||
}
|
||||
.CodeMirror-vscrollbar {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.CodeMirror-scroll {
|
||||
overflow: hidden !important;
|
||||
}
|
||||
|
||||
.CodeMirror-lines {
|
||||
line-height: 20px;
|
||||
padding: 5px 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.cm-expression {
|
||||
background: #007bff;
|
||||
padding: 0px 5px;
|
||||
margin: 0 1px;
|
||||
color: #fff;
|
||||
font-size: 12px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
&-buttonWrapper {
|
||||
height: auto;
|
||||
}
|
||||
&-button,
|
||||
&-buttonWrapper-button {
|
||||
height: 100%;
|
||||
background-color: #f7f7f9;
|
||||
padding: 4px 8px;
|
||||
border-radius: 0 var(--input-default-default-top-left-border-radius)
|
||||
var(--input-default-default-bottom-left-border-radius) 0;
|
||||
border-left: 0;
|
||||
&:not(:disabled):not(.is-disabled) {
|
||||
&:hover,
|
||||
&:hover:active {
|
||||
border-color: #e6f0ff;
|
||||
background-color: #e6f0ff;
|
||||
border-left-width: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-icon {
|
||||
font-size: #{px2rem(14px)};
|
||||
&:not(:last-child) {
|
||||
margin-right: var(--fontSizeSm);
|
||||
}
|
||||
|
||||
&.is-filled {
|
||||
fill: var(--primary);
|
||||
color: var(--primary);
|
||||
}
|
||||
}
|
||||
|
||||
&-placeholder {
|
||||
position: absolute;
|
||||
line-height: 30px;
|
||||
top: 0;
|
||||
left: 14px;
|
||||
font-size: 12px;
|
||||
color: var(--text--muted-color);
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
&-tooltip {
|
||||
position: absolute;
|
||||
top: 6px;
|
||||
height: 18px;
|
||||
z-index: 1;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
&.clearable {
|
||||
.ae-TplResultBox {
|
||||
padding-right: 28px;
|
||||
}
|
||||
}
|
||||
|
||||
.cm-expression-text {
|
||||
max-width: 48px;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,67 @@
|
||||
.ae-TreeOptionControl {
|
||||
&-header {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
height: #{px2rem(24px)};
|
||||
margin-bottom: #{px2rem(12px)};
|
||||
}
|
||||
|
||||
&-footer > * {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
.ae-TreeOptionControl-Modal {
|
||||
.ae-TreeOptionControl-content {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.ae-TreeOptionControlItem {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
&:not(:first-child) {
|
||||
margin-top: var(--gap-sm);
|
||||
}
|
||||
&-parent {
|
||||
margin-top: var(--gap-sm);
|
||||
}
|
||||
&-son {
|
||||
margin-top: var(--gap-sm);
|
||||
padding-left: #{px2rem(32px)};
|
||||
}
|
||||
&-dragging {
|
||||
height: 0 !important;
|
||||
padding: 0;
|
||||
border-top: 2px solid var(--primary);
|
||||
overflow: hidden;
|
||||
background: #e9effd;
|
||||
}
|
||||
&-dragBar {
|
||||
display: inline-flex;
|
||||
margin-left: 0;
|
||||
margin-right: var(--gap-sm);
|
||||
cursor: move;
|
||||
color: #8c8c8c;
|
||||
}
|
||||
// &-btns {
|
||||
// }
|
||||
&-input-label {
|
||||
flex: 1;
|
||||
margin-right: var(--gap-sm);
|
||||
margin-bottom: 0;
|
||||
}
|
||||
&-input-value {
|
||||
margin-right: var(--gap-sm);
|
||||
}
|
||||
&-dropdown {
|
||||
margin-right: var(--gap-sm);
|
||||
svg {
|
||||
font-size: var(--Button--sm-fontSize);
|
||||
}
|
||||
.m-r-xs {
|
||||
margin-right: 2px;
|
||||
font-size: #{px2rem(12px)};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
108
packages/amis-editor-core/scss/control/_validation-control.scss
Normal file
108
packages/amis-editor-core/scss/control/_validation-control.scss
Normal file
@@ -0,0 +1,108 @@
|
||||
.ae-ValidationControl {
|
||||
position: relative;
|
||||
min-height: 1px; // form-item空内容时有个margin,会导致collapse上的增加按钮偏移
|
||||
|
||||
&-dropdown {
|
||||
@include flexBox(row, space-between);
|
||||
position: absolute;
|
||||
top: #{px2rem(-45px)};
|
||||
right: #{px2rem(20px)};
|
||||
height: $category-2-height;
|
||||
|
||||
&-btn {
|
||||
color: #141a25;
|
||||
background: transparent !important;
|
||||
border: none !important;
|
||||
}
|
||||
}
|
||||
|
||||
header {
|
||||
@include flexBox();
|
||||
width: 100%;
|
||||
height: #{px2rem(24px)};
|
||||
margin-bottom: #{px2rem(10px)};
|
||||
}
|
||||
|
||||
&-item {
|
||||
@include flexBox(column, flex-start, flex-start);
|
||||
width: 100%;
|
||||
padding: 0;
|
||||
|
||||
&:not(:last-child) {
|
||||
margin-bottom: #{px2rem(10px)};
|
||||
}
|
||||
|
||||
section {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.ae-ValidationControl-item-control {
|
||||
@include flexBox(row, space-between);
|
||||
margin-bottom: #{px2rem(10px)};
|
||||
|
||||
&.is-active {
|
||||
margin-bottom: #{px2rem(5px)};
|
||||
}
|
||||
|
||||
& > div {
|
||||
@include flexBox(row, flex-end);
|
||||
|
||||
hr {
|
||||
border: 0;
|
||||
margin: 0;
|
||||
border-left: 1px solid #e6e6e8;
|
||||
height: #{px2rem(16px)};
|
||||
vertical-align: middle;
|
||||
margin: 0 #{px2rem(8px)};
|
||||
}
|
||||
}
|
||||
|
||||
.ae-ValidationControl-item-actions {
|
||||
@include flexBox(row, flex-end);
|
||||
|
||||
.ae-ValidationControl-item-action {
|
||||
position: relative;
|
||||
top: #{px2rem(2px)};
|
||||
right: 5px;
|
||||
|
||||
i {
|
||||
color: #83868c;
|
||||
font-size: #{px2rem(16px)};
|
||||
|
||||
&:hover {
|
||||
color: var(--primary);
|
||||
}
|
||||
}
|
||||
|
||||
&:not(:last-child) {
|
||||
margin-right: #{px2rem(10px)};
|
||||
}
|
||||
|
||||
&:hover {
|
||||
& > svg,
|
||||
& > svg path {
|
||||
fill: var(--primary);
|
||||
}
|
||||
}
|
||||
|
||||
& > svg,
|
||||
& > svg path {
|
||||
fill: #83868c;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ae-ValidationControl-item-input {
|
||||
@include flexBox(column, flex-start, flex-start);
|
||||
@include panel-group-bg();
|
||||
margin-top: px2rem(12px);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ae-ValidationControl-label-code {
|
||||
background-color: #666;
|
||||
padding: 0 4px;
|
||||
border-radius: 2px;
|
||||
}
|
||||
Reference in New Issue
Block a user