Merge pull request #222 from DevDengChao/codex/lint-components

fix: lint src components
pull/881/head
芋道源码 2026-05-23 21:35:25 +08:00 committed by GitHub
commit 02c0d0cb3b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
55 changed files with 290 additions and 270 deletions

View File

@ -165,8 +165,8 @@ $toolbar-position: -55px;
width: 80px; width: 80px;
height: 25px; height: 25px;
font-size: 12px; font-size: 12px;
color: #6a6a6a;
line-height: 25px; line-height: 25px;
color: #6a6a6a;
text-align: center; text-align: center;
background: #fff; background: #fff;
box-shadow: box-shadow:

View File

@ -94,9 +94,9 @@ const handleCloneComponent = (component: DiyComponent<any>) => {
<style scoped lang="scss"> <style scoped lang="scss">
.editor-left { .editor-left {
z-index: 1; z-index: 1;
flex-shrink: 0;
user-select: none;
box-shadow: 8px 0 8px -8px rgb(0 0 0 / 12%); box-shadow: 8px 0 8px -8px rgb(0 0 0 / 12%);
user-select: none;
flex-shrink: 0;
:deep(.el-collapse) { :deep(.el-collapse) {
border-top: none; border-top: none;

View File

@ -55,12 +55,12 @@ const handleToggleFab = () => {
/* 模态背景 */ /* 模态背景 */
.modal-bg { .modal-bg {
position: absolute; position: absolute;
left: calc(50% - 375px / 2);
top: 0; top: 0;
left: calc(50% - 375px / 2);
z-index: 11; z-index: 11;
width: 375px; width: 375px;
height: 100%; height: 100%;
background-color: rgba(#000000, 0.4); background-color: rgb(0 0 0 / 40%);
} }
.fab-icon { .fab-icon {

View File

@ -192,39 +192,39 @@ const handleAppLinkChange = (appLink: AppLink) => {
<style scoped lang="scss"> <style scoped lang="scss">
.hot-zone { .hot-zone {
position: absolute; position: absolute;
background: var(--el-color-primary-light-7); z-index: 10;
opacity: 0.8;
border: 1px solid var(--el-color-primary);
color: var(--el-color-primary);
font-size: 16px;
display: flex; display: flex;
font-size: 16px;
color: var(--el-color-primary);
cursor: move;
background: var(--el-color-primary-light-7);
border: 1px solid var(--el-color-primary);
opacity: 0.8;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
cursor: move;
z-index: 10;
/* 控制点 */ /* 控制点 */
.ctrl-dot { .ctrl-dot {
position: absolute; position: absolute;
z-index: 11;
width: 8px; width: 8px;
height: 8px; height: 8px;
border-radius: 50%;
border: inherit;
background-color: #fff; background-color: #fff;
z-index: 11; border: inherit;
border-radius: 50%;
} }
.delete { .delete {
display: none;
position: absolute; position: absolute;
top: 0; top: 0;
right: 0; right: 0;
display: none;
padding: 2px 2px 6px 6px; padding: 2px 2px 6px 6px;
background-color: var(--el-color-primary);
border-radius: 0 0 0 80%;
cursor: pointer;
color: #fff; color: #fff;
text-align: right; text-align: right;
cursor: pointer;
background-color: var(--el-color-primary);
border-radius: 0 0 0 80%;
} }
&:hover { &:hover {

View File

@ -28,15 +28,15 @@ const props = defineProps<{ property: HotZoneProperty }>()
<style scoped lang="scss"> <style scoped lang="scss">
.hot-zone { .hot-zone {
position: absolute; position: absolute;
background: var(--el-color-primary-light-7); z-index: 10;
opacity: 0.8;
border: 1px solid var(--el-color-primary);
color: var(--el-color-primary);
font-size: 14px;
display: flex; display: flex;
font-size: 14px;
color: var(--el-color-primary);
cursor: move;
background: var(--el-color-primary-light-7);
border: 1px solid var(--el-color-primary);
opacity: 0.8;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
cursor: move;
z-index: 10;
} }
</style> </style>

View File

@ -42,22 +42,22 @@ const handleOpenEditDialog = () => {
<style scoped lang="scss"> <style scoped lang="scss">
.hot-zone { .hot-zone {
position: absolute; position: absolute;
display: flex;
font-size: 12px;
color: #fff;
cursor: move;
background: #409effbf; background: #409effbf;
border: 1px solid var(--el-color-primary); border: 1px solid var(--el-color-primary);
color: #fff;
font-size: 12px;
display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
cursor: move;
/* 控制点 */ /* 控制点 */
.ctrl-dot { .ctrl-dot {
position: absolute; position: absolute;
width: 4px; width: 4px;
height: 4px; height: 4px;
border-radius: 50%;
background-color: #fff; background-color: #fff;
border-radius: 50%;
} }
} }
</style> </style>

View File

@ -103,13 +103,16 @@ watch(
.el-carousel__indicator { .el-carousel__indicator {
padding-top: 0; padding-top: 0;
padding-bottom: 0; padding-bottom: 0;
.el-carousel__button { .el-carousel__button {
--el-carousel-indicator-height: 6px; --el-carousel-indicator-height: 6px;
--el-carousel-indicator-width: 6px; --el-carousel-indicator-width: 6px;
--el-carousel-indicator-out-color: #ff6000; --el-carousel-indicator-out-color: #ff6000;
border-radius: 6px; border-radius: 6px;
} }
} }
.el-carousel__indicator.is-active { .el-carousel__indicator.is-active {
.el-carousel__button { .el-carousel__button {
--el-carousel-indicator-width: 12px; --el-carousel-indicator-width: 12px;

View File

@ -93,8 +93,8 @@ defineOptions({ name: 'NavigationBarCellProperty' })
const props = withDefaults( const props = withDefaults(
defineProps<{ defineProps<{
modelValue: NavigationBarCellProperty[] modelValue?: NavigationBarCellProperty[]
isMp: boolean isMp?: boolean
}>(), }>(),
{ {
modelValue: () => [], modelValue: () => [],

View File

@ -67,10 +67,10 @@ const getSearchProp = computed(() => (cell: NavigationBarCellProperty) => {
.navigation-bar { .navigation-bar {
display: flex; display: flex;
height: 50px; height: 50px;
padding: 0 6px;
background: #fff; background: #fff;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
padding: 0 6px;
/* 左边 */ /* 左边 */
.left { .left {

View File

@ -583,12 +583,12 @@ $toolbar-height: 42px;
gap: 8px; gap: 8px;
:deep(.el-tag) { :deep(.el-tag) {
box-shadow: 0 2px 8px 0 rgba(0, 0, 0, 0.1);
border: none; border: none;
box-shadow: 0 2px 8px 0 rgb(0 0 0 / 10%);
.el-tag__content { .el-tag__content {
width: 100%;
display: flex; display: flex;
width: 100%;
align-items: center; align-items: center;
justify-content: flex-start; justify-content: flex-start;

View File

@ -27,7 +27,7 @@ const { getPrefixCls } = useDesign()
const prefixCls = getPrefixCls('form') const prefixCls = getPrefixCls('form')
export default defineComponent({ export default defineComponent({
// eslint-disable-next-line vue/no-reserved-component-names
name: 'Form', name: 'Form',
props: { props: {
// Form // Form

View File

@ -64,9 +64,9 @@ const showPreview = computed(() => {
} }
.iframe-preview { .iframe-preview {
overflow: hidden;
border: 1px solid #dcdfe6; border: 1px solid #dcdfe6;
border-radius: 4px; border-radius: 4px;
overflow: hidden;
} }
.iframe-content { .iframe-content {
@ -76,11 +76,11 @@ const showPreview = computed(() => {
.iframe-placeholder { .iframe-placeholder {
display: flex; display: flex;
align-items: center;
justify-content: center;
min-height: 200px; min-height: 200px;
background-color: #fafafa;
border: 1px dashed #dcdfe6; border: 1px dashed #dcdfe6;
border-radius: 4px; border-radius: 4px;
background-color: #fafafa; align-items: center;
justify-content: center;
} }
</style> </style>

View File

@ -14,7 +14,6 @@ defineProps({
title: propTypes.string.def(''), title: propTypes.string.def(''),
schema: { schema: {
type: Array as PropType<Array<string | TipSchema>>, type: Array as PropType<Array<string | TipSchema>>,
required: true,
default: () => [] default: () => []
}, },
showIndex: propTypes.bool.def(true), showIndex: propTypes.bool.def(true),

View File

@ -26,6 +26,7 @@ const { modelValue, color } = useVModels(props, emit)
<style scoped lang="scss"> <style scoped lang="scss">
:deep(.el-input-group__append) { :deep(.el-input-group__append) {
padding: 0; padding: 0;
.el-color-picker__trigger { .el-color-picker__trigger {
padding: 0; padding: 0;
border-left: none; border-left: none;

View File

@ -225,15 +225,16 @@ const eachCube = (callback: (x: number, y: number, cube: Cube) => void) => {
<style lang="scss" scoped> <style lang="scss" scoped>
.cube-table { .cube-table {
position: relative; position: relative;
border-spacing: 0;
border-collapse: collapse; border-collapse: collapse;
border-spacing: 0;
.cube { .cube {
border: 1px solid var(--el-border-color);
text-align: center;
color: var(--el-text-color-secondary); color: var(--el-text-color-secondary);
text-align: center;
cursor: pointer; cursor: pointer;
border: 1px solid var(--el-border-color);
box-sizing: border-box; box-sizing: border-box;
&.active { &.active {
background: var(--el-color-primary-light-9); background: var(--el-color-primary-light-9);
} }
@ -242,28 +243,28 @@ const eachCube = (callback: (x: number, y: number, cube: Cube) => void) => {
.hot-area { .hot-area {
position: absolute; position: absolute;
display: flex; display: flex;
color: var(--el-color-primary);
cursor: pointer;
background: var(--el-color-primary-light-8);
border: 1px solid var(--el-color-primary);
border-collapse: collapse;
border-spacing: 0;
box-sizing: border-box;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
border: 1px solid var(--el-color-primary);
background: var(--el-color-primary-light-8);
color: var(--el-color-primary);
box-sizing: border-box;
border-spacing: 0;
border-collapse: collapse;
cursor: pointer;
.btn-delete { .btn-delete {
z-index: 1;
position: absolute; position: absolute;
top: -8px; top: -8px;
right: -8px; right: -8px;
height: 16px; z-index: 1;
width: 16px;
display: flex; display: flex;
width: 16px;
height: 16px;
background-color: #fff;
border-radius: 50%;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
border-radius: 50%;
background-color: #fff;
} }
} }
} }

View File

@ -51,14 +51,14 @@ onMounted(async () => {
<style lang="scss"> <style lang="scss">
.markdown-view { .markdown-view {
font-family: PingFang SC; max-width: 100%;
font-family: "PingFang SC";
font-size: 0.95rem; font-size: 0.95rem;
font-weight: 400; font-weight: 400;
line-height: 1.6rem; line-height: 1.6rem;
letter-spacing: 0em; letter-spacing: 0;
text-align: left;
color: #3b3e55; color: #3b3e55;
max-width: 100%; text-align: left;
pre { pre {
position: relative; position: relative;
@ -69,22 +69,23 @@ onMounted(async () => {
} }
code.hljs { code.hljs {
border-radius: 6px;
padding-top: 20px;
width: auto; width: auto;
@media screen and (min-width: 1536px) { padding-top: 20px;
border-radius: 6px;
@media screen and (width >= 1536px) {
width: 960px; width: 960px;
} }
@media screen and (max-width: 1536px) and (min-width: 1024px) { @media screen and (width <= 1536px) and (width >= 1024px) {
width: calc(100vw - 400px - 64px - 32px * 2); width: calc(100vw - 400px - 64px - 32px * 2);
} }
@media screen and (max-width: 1024px) and (min-width: 768px) { @media screen and (width <= 1024px) and (width >= 768px) {
width: calc(100vw - 32px * 2); width: calc(100vw - 32px * 2);
} }
@media screen and (max-width: 768px) { @media screen and (width <= 768px) {
width: calc(100vw - 16px * 2); width: calc(100vw - 16px * 2);
} }
} }
@ -107,9 +108,9 @@ onMounted(async () => {
h4, h4,
h5, h5,
h6 { h6 {
color: var(--color-G900);
margin: 24px 0 8px; margin: 24px 0 8px;
font-weight: 600; font-weight: 600;
color: #3b3e55;
} }
h1 { h1 {
@ -145,8 +146,8 @@ onMounted(async () => {
/* 列表(有序,无序) */ /* 列表(有序,无序) */
ul, ul,
ol { ol {
margin: 0 0 8px 0;
padding: 0; padding: 0;
margin: 0 0 8px;
font-size: 16px; font-size: 16px;
line-height: 24px; line-height: 24px;
color: #3b3e55; // var(--color-CG600); color: #3b3e55; // var(--color-CG600);
@ -158,8 +159,8 @@ onMounted(async () => {
} }
ol > li { ol > li {
list-style-type: decimal;
margin-bottom: 1rem; margin-bottom: 1rem;
list-style-type: decimal;
// , // ,
// &:nth-child(n + 10) { // &:nth-child(n + 10) {
// margin-left: 30px; // margin-left: 30px;
@ -171,23 +172,23 @@ onMounted(async () => {
} }
ul > li { ul > li {
list-style-type: disc;
font-size: 16px;
line-height: 24px;
margin-right: 11px; margin-right: 11px;
margin-bottom: 1rem; margin-bottom: 1rem;
font-size: 16px;
line-height: 24px;
color: #3b3e55; // var(--color-G900); color: #3b3e55; // var(--color-G900);
list-style-type: disc;
} }
ol ul, ol ul,
ol ul > li, ol ul > li,
ul ul, ul ul,
ul ul li { ul ul li {
margin-bottom: 1rem;
margin-left: 6px;
// list-style: circle; // list-style: circle;
font-size: 16px; font-size: 16px;
list-style: none; list-style: none;
margin-left: 6px;
margin-bottom: 1rem;
} }
ul ul ul, ul ul ul,

View File

@ -31,7 +31,7 @@ import { ElTag } from 'element-plus'
defineOptions({ name: 'OperateLogV2' }) defineOptions({ name: 'OperateLogV2' })
interface Props { interface Props {
logList: OperateLogVO[] // logList?: OperateLogVO[] //
} }
withDefaults(defineProps<Props>(), { withDefaults(defineProps<Props>(), {

View File

@ -246,9 +246,9 @@ onMounted(() => {
<style lang="scss" scoped> <style lang="scss" scoped>
.simple-process-model-container { .simple-process-model-container {
position: relative;
width: 100%; width: 100%;
height: 100%; height: 100%;
position: relative;
overflow: hidden; overflow: hidden;
user-select: none; // user-select: none; //
} }

View File

@ -9,7 +9,7 @@ import { set } from 'lodash-es'
import { Pagination, TableColumn, TableSetPropsType, TableSlotDefault } from '@/types/table' import { Pagination, TableColumn, TableSetPropsType, TableSlotDefault } from '@/types/table'
export default defineComponent({ export default defineComponent({
// eslint-disable-next-line vue/no-reserved-component-names
name: 'Table', name: 'Table',
props: { props: {
pageSize: propTypes.number.def(10), pageSize: propTypes.number.def(10),

View File

@ -33,8 +33,8 @@ import { ElTable } from 'element-plus'
defineOptions({ name: 'TableSelectForm' }) defineOptions({ name: 'TableSelectForm' })
withDefaults( withDefaults(
defineProps<{ defineProps<{
modelValue: any[] modelValue?: any[]
title: string title?: string
}>(), }>(),
{ modelValue: () => [], title: '选择' } { modelValue: () => [], title: '选择' }
) )

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="upload-box"> <div class="upload-box" :style="uploadStyle">
<el-upload <el-upload
:id="uuid" :id="uuid"
:accept="fileType.join(',')" :accept="fileType.join(',')"
@ -82,6 +82,13 @@ const props = defineProps({
showBtnText: propTypes.bool.def(true), // showBtnText: propTypes.bool.def(true), //
directory: propTypes.string.def(undefined) // ==> undefined directory: propTypes.string.def(undefined) // ==> undefined
}) })
const uploadStyle = computed(() => ({
'--upload-width': props.width,
'--upload-height': props.height,
'--upload-border-radius': props.borderradius
}))
const { t } = useI18n() // const { t } = useI18n() //
const message = useMessage() // const message = useMessage() //
// id // id
@ -167,11 +174,11 @@ const uploadError = () => {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
width: v-bind(width); width: var(--upload-width);
height: v-bind(height); height: var(--upload-height);
overflow: hidden; overflow: hidden;
border: 1px dashed var(--el-border-color-darker); border: 1px dashed var(--el-border-color-darker);
border-radius: v-bind(borderradius); border-radius: var(--upload-border-radius);
transition: var(--el-transition-duration-fast); transition: var(--el-transition-duration-fast);
&:hover { &:hover {
@ -192,7 +199,7 @@ const uploadError = () => {
overflow: hidden; overflow: hidden;
background-color: transparent; background-color: transparent;
border: 1px dashed var(--el-border-color-darker); border: 1px dashed var(--el-border-color-darker);
border-radius: v-bind(borderradius); border-radius: var(--upload-border-radius);
&:hover { &:hover {
border: 1px dashed var(--el-color-primary); border: 1px dashed var(--el-color-primary);

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="upload-box"> <div class="upload-box" :style="uploadStyle">
<el-upload <el-upload
v-model:file-list="fileList" v-model:file-list="fileList"
:accept="fileType.join(',')" :accept="fileType.join(',')"
@ -85,6 +85,12 @@ const props = defineProps({
directory: propTypes.string.def(undefined) // ==> undefined directory: propTypes.string.def(undefined) // ==> undefined
}) })
const uploadStyle = computed(() => ({
'--upload-width': props.width,
'--upload-height': props.height,
'--upload-border-radius': props.borderradius
}))
const { uploadUrl, httpRequest } = useUpload(props.directory) const { uploadUrl, httpRequest } = useUpload(props.directory)
const fileList = ref<UploadUserFile[]>([]) const fileList = ref<UploadUserFile[]>([])
@ -238,7 +244,7 @@ const handleExceed = () => {
padding: 0; padding: 0;
overflow: hidden; overflow: hidden;
border: 1px dashed var(--el-border-color-darker); border: 1px dashed var(--el-border-color-darker);
border-radius: v-bind(borderradius); border-radius: var(--upload-border-radius);
&:hover { &:hover {
border: 1px dashed var(--el-color-primary); border: 1px dashed var(--el-color-primary);
@ -252,10 +258,10 @@ const handleExceed = () => {
.el-upload-list__item, .el-upload-list__item,
.el-upload--picture-card { .el-upload--picture-card {
width: v-bind(width); width: var(--upload-width);
height: v-bind(height); height: var(--upload-height);
background-color: transparent; background-color: transparent;
border-radius: v-bind(borderradius); border-radius: var(--upload-border-radius);
} }
.upload-image { .upload-image {

View File

@ -158,11 +158,13 @@ defineExpose({ open }) // 提供 open 方法,用于打开弹窗
.el-transfer { .el-transfer {
display: flex; display: flex;
} }
.el-transfer__buttons { .el-transfer__buttons {
display: flex !important; display: flex !important;
flex-direction: column-reverse; flex-direction: column-reverse;
justify-content: center; justify-content: center;
gap: 20px; gap: 20px;
.el-transfer__button:nth-child(2) { .el-transfer__button:nth-child(2) {
margin: 0; margin: 0;
} }

View File

@ -12,7 +12,7 @@ import { isFunction, isObject, some } from 'min-dash'
const WILDCARD = '*' const WILDCARD = '*'
function CamundaModdleExtension(eventBus) { function CamundaModdleExtension(eventBus) {
// eslint-disable-next-line @typescript-eslint/no-this-alias
const self = this const self = this
eventBus.on('moddleCopy.canCopyProperty', function (context) { eventBus.on('moddleCopy.canCopyProperty', function (context) {

View File

@ -141,8 +141,8 @@ watch(
.header-editor { .header-editor {
.header-list { .header-list {
max-height: 400px; max-height: 400px;
overflow-y: auto;
margin-bottom: 16px; margin-bottom: 16px;
overflow-y: auto;
} }
.header-item { .header-item {
@ -156,8 +156,8 @@ watch(
} }
.separator { .separator {
color: #606266;
font-weight: 500; font-weight: 500;
color: #606266;
} }
.header-value { .header-value {

View File

@ -18,7 +18,7 @@
</el-button-group> </el-button-group>
<el-icon v-if="valid" color="green" style="margin-left: 8px"><CircleCheckFilled /></el-icon> <el-icon v-if="valid" color="green" style="margin-left: 8px"><CircleCheckFilled /></el-icon>
</div> </div>
<div style="margin-top: 10px; display: flex; align-items: center"> <div style=" display: flex;margin-top: 10px; align-items: center">
<span>条件</span> <span>条件</span>
<el-input <el-input
v-model="condition" v-model="condition"