-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
360 additions
and
335 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
> 1% | ||
last 2 versions | ||
not dead | ||
> 1% | ||
last 2 versions | ||
not dead |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,19 @@ | ||
/** | ||
* store 状态管理 | ||
* @copyright 火星科技 mars3d.cn | ||
* @author 火星吴彦祖 2022-02-19 | ||
*/ | ||
import { Store, createStore } from "vuex" | ||
import { InjectionKey } from "vue" | ||
|
||
export interface Test { | ||
count?: number | ||
} | ||
|
||
export const key: InjectionKey<Store<Test>> = Symbol("test") | ||
|
||
export const store = createStore<Test>({ | ||
state: { | ||
count: 0 | ||
} | ||
}) | ||
/** | ||
* store 状态管理 | ||
* @copyright 火星科技 mars3d.cn | ||
* @author 火星吴彦祖 2022-02-19 | ||
*/ | ||
import { Store, createStore } from "vuex" | ||
import { InjectionKey } from "vue" | ||
|
||
export interface Test { | ||
count?: number | ||
} | ||
|
||
export const key: InjectionKey<Store<Test>> = Symbol("test") | ||
|
||
export const store = createStore<Test>({ | ||
state: { | ||
count: 0 | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,42 @@ | ||
<template> | ||
<a-input class="mars-input" v-bind="attrs"> | ||
<template v-for="(comp, name) in slots" :key="name" v-slot:[name]> | ||
<component :is="comp" /> | ||
</template> | ||
</a-input> | ||
</template> | ||
<script lang="ts"> | ||
import { useAttrs, useSlots, defineComponent } from "vue" | ||
export default defineComponent({ | ||
name: "mars-input", | ||
inheritAttrs: false, | ||
setup() { | ||
const attrs = useAttrs() | ||
const slots = useSlots() | ||
return { | ||
attrs, | ||
slots | ||
} | ||
} | ||
}) | ||
</script> | ||
<style lang="less" scoped> | ||
.mars-input { | ||
color: @mars-basecolor; | ||
background-color: @form-input-background !important; | ||
border-color: @border-color-ordinary; | ||
:deep(.ant-input) { | ||
background-color: @form-input-background !important; | ||
border-color: @border-color-ordinary; | ||
color: @mars-basecolor; | ||
} | ||
:deep(.ant-input-suffix .anticon) { | ||
color: @mars-basecolor; | ||
} | ||
} | ||
.mars-input[disabled] { | ||
color: @mars-disable-color; | ||
} | ||
</style> | ||
<template> | ||
<a-input class="mars-input" v-bind="attrs"> | ||
<template v-for="(comp, name) in slots" :key="name" v-slot:[name]> | ||
<component :is="comp" /> | ||
</template> | ||
</a-input> | ||
</template> | ||
<script lang="ts"> | ||
import { useAttrs, useSlots, defineComponent } from "vue" | ||
export default defineComponent({ | ||
name: "mars-input", | ||
inheritAttrs: false, | ||
setup() { | ||
const attrs = useAttrs() | ||
const slots = useSlots() | ||
return { | ||
attrs, | ||
slots | ||
} | ||
} | ||
}) | ||
</script> | ||
<style lang="less" scoped> | ||
.mars-input { | ||
color: @mars-basecolor; | ||
background-color: @form-input-background !important; | ||
border-color: @border-color-ordinary; | ||
font-size: 12px !important; | ||
:deep(.ant-input) { | ||
background-color: @form-input-background !important; | ||
border-color: @border-color-ordinary; | ||
color: @mars-basecolor; | ||
} | ||
:deep(.ant-input-suffix .anticon) { | ||
color: @mars-basecolor; | ||
} | ||
} | ||
.mars-input[disabled] { | ||
color: @mars-disable-color; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.