Skip to content

Commit

Permalink
feat(milestone): [milestone] 修改示例适配默认主题 (#2561)
Browse files Browse the repository at this point in the history
  • Loading branch information
chenxi-20 authored Nov 27, 2024
1 parent 83c5e04 commit 1df0f4d
Show file tree
Hide file tree
Showing 9 changed files with 34 additions and 46 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ const statusMap = ref({
// 对应 status = completed
completed: '#1890ff',
// 对应 status = doing
doing: '#7eb7fc',
doing: '#e8faff',
// 对应 status = back
back: '#ff8800',
back: '#edf7df',
// 对应 status = end
end: '#faad14',
// 对应 status = cancel
cancel: '#fce2e0'
cancel: '#f230301A'
})
// 数据源
Expand Down
8 changes: 4 additions & 4 deletions examples/sites/demos/pc/app/milestone/basic-usage.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,18 @@ test('基本用法', async ({ page }) => {
'box-shadow': 'none'
},
{
'background-color': 'rgb(126, 183, 252)',
'background-color': 'rgb(232, 250, 255)',
'color': 'rgb(255, 255, 255)',
'box-shadow': 'none'
},
{
'background-color': 'rgb(255, 255, 255)',
'color': 'rgb(252, 226, 224)',
'color': 'rgba(242, 48, 48, 0.1)',
'box-shadow': 'none'
},
{
'background-color': 'rgb(255, 255, 255)',
'color': 'rgb(255, 136, 0)',
'color': 'rgb(237, 247, 223)',
'box-shadow': 'none'
},
{
Expand All @@ -56,7 +56,7 @@ test('基本用法', async ({ page }) => {
]
const titles = ['completed 状态', 'completed 状态', 'doing 状态', 'cancel 状态', 'back 状态', 'end 状态']
const flagContents = [//, /test7使vui/, /test8/, /test6/]
const flagLineColors = ['rgb(255, 136, 0)', 'rgb(255, 136, 0)', 'rgb(126, 183, 252)', 'rgb(252, 226, 224)']
const flagLineColors = ['rgb(237, 247, 223)', 'rgb(237, 247, 223)', 'rgb(232, 250, 255)', 'rgba(242, 48, 48, 0.1)']

await expect(nodes).toHaveCount(nodeCount)
await expect(nodeLines).toHaveCount(nodeCount)
Expand Down
6 changes: 3 additions & 3 deletions examples/sites/demos/pc/app/milestone/basic-usage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ export default {
// 对应 status = completed
completed: '#1890ff',
// 对应 status = doing
doing: '#7eb7fc',
doing: '#e8faff',
// 对应 status = back
back: '#ff8800',
back: '#edf7df',
// 对应 status = end
end: '#faad14',
// 对应 status = cancel
cancel: '#fce2e0'
cancel: '#f230301A'
},
// 数据源
milestoneData: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,12 @@
import { ref } from 'vue'
import { TinyMilestone } from '@opentiny/vue'
const timeActive1 = ref(1)
const normalActive = ref(2)
const advancedActive = ref(2)
const statusMap = ref({
completed: 'var(--tv-color-bg-disabled-control-active)',
doing: '#7ED321',
back: '#f5222d',
completed: '#f0f7ff',
doing: '#e8faff',
back: '#edf7df',
end: '#faad14',
cancel: '#d9d9d9'
cancel: '#f230301A'
})
const milestoneData = ref([
{
Expand Down
11 changes: 4 additions & 7 deletions examples/sites/demos/pc/app/milestone/custom-flag.vue
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,12 @@ export default {
},
data() {
return {
timeActive1: 1,
normalActive: 2,
advancedActive: 2,
statusMap: {
completed: 'var(--tv-color-bg-disabled-control-active)',
doing: '#7ED321',
back: '#f5222d',
completed: '#f0f7ff',
doing: '#e8faff',
back: '#edf7df',
end: '#faad14',
cancel: '#d9d9d9'
cancel: '#f230301A'
},
milestoneData: [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ import { ref } from 'vue'
import { TinyMilestone } from '@opentiny/vue'
const statusMap = ref({
completed: 'var(--tv-color-bg-disabled-control-active)',
doing: '#7ED321',
back: '#f5222d',
completed: '#f0f7ff',
doing: '#e8faff',
back: '#edf7df',
end: '#faad14',
cancel: '#d9d9d9'
cancel: '#f230301A'
})
const milestoneData = ref([
{
Expand Down
8 changes: 4 additions & 4 deletions examples/sites/demos/pc/app/milestone/data-field-mapping.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@ export default {
data() {
return {
statusMap: {
completed: 'var(--tv-color-bg-disabled-control-active)',
doing: '#7ED321',
back: '#f5222d',
completed: '#f0f7ff',
doing: '#e8faff',
back: '#edf7df',
end: '#faad14',
cancel: '#d9d9d9'
cancel: '#f230301A'
},
milestoneData: [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,12 @@
import { ref } from 'vue'
import { TinyMilestone, TinyNotify } from '@opentiny/vue'
const timeActive1 = ref(1)
const normalActive = ref(2)
const advancedActive = ref(2)
const statusMap = ref({
completed: 'var(--tv-color-bg-disabled-control-active)',
doing: '#7ED321',
back: '#f5222d',
completed: '#f0f7ff',
doing: '#e8faff',
back: '#edf7df',
end: '#faad14',
cancel: '#d9d9d9'
cancel: '#f230301A'
})
const milestoneData = ref([
{
Expand Down
11 changes: 4 additions & 7 deletions examples/sites/demos/pc/app/milestone/milestone-events.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,12 @@ export default {
},
data() {
return {
timeActive1: 1,
normalActive: 2,
advancedActive: 2,
statusMap: {
completed: 'var(--tv-color-bg-disabled-control-active)',
doing: '#7ED321',
back: '#f5222d',
completed: '#f0f7ff',
doing: '#e8faff',
back: '#edf7df',
end: '#faad14',
cancel: '#d9d9d9'
cancel: '#f230301A'
},
milestoneData: [
{
Expand Down

0 comments on commit 1df0f4d

Please sign in to comment.