This commit is contained in:
tamaina 2022-04-23 00:57:28 +09:00
parent d240c323ee
commit 9d02728f67
20 changed files with 38 additions and 153 deletions

View file

@ -42,7 +42,7 @@
<script lang="ts" setup>
import { ref, computed, onMounted, onBeforeUnmount } from 'vue';
import * as tinycolor from 'tinycolor2';
import tinycolor from 'tinycolor2';
withDefaults(defineProps<{
thickness: number;

View file

@ -29,7 +29,7 @@ import {
import 'chartjs-adapter-date-fns';
import { enUS } from 'date-fns/locale';
import zoomPlugin from 'chartjs-plugin-zoom';
import gradient from 'chartjs-plugin-gradient';
//import gradient from 'chartjs-plugin-gradient';
import * as os from '@/os';
import { defaultStore } from '@/store';
import MkChartTooltip from '@/components/chart-tooltip.vue';
@ -50,7 +50,7 @@ Chart.register(
SubTitle,
Filler,
zoomPlugin,
gradient,
//gradient,
);
const sum = (...arr) => arr.reduce((r, a) => r.map((b, i) => a[i] + b));
@ -221,7 +221,7 @@ export default defineComponent({
borderJoinStyle: 'round',
borderRadius: props.bar ? 3 : undefined,
backgroundColor: props.bar ? (x.color ? x.color : getColor(i)) : alpha(x.color ? x.color : getColor(i), 0.1),
gradient: props.bar ? undefined : {
/*gradient: props.bar ? undefined : {
backgroundColor: {
axis: 'y',
colors: {
@ -229,7 +229,7 @@ export default defineComponent({
[maxes[i]]: alpha(x.color ? x.color : getColor(i), 0.2),
},
},
},
},*/
barPercentage: 0.9,
categoryPercentage: 0.9,
fill: x.type === 'area',
@ -340,7 +340,7 @@ export default defineComponent({
},
}
} : undefined,
gradient,
//gradient,
},
},
plugins: [{

View file

@ -38,7 +38,7 @@
<script lang="ts">
import { computed, defineComponent, onMounted, onUnmounted, PropType, ref, inject } from 'vue';
import * as tinycolor from 'tinycolor2';
import tinycolor from 'tinycolor2';
import { popupMenu } from '@/os';
import { url } from '@/config';
import { scrollToTop } from '@/scripts/scroll';

View file

@ -16,7 +16,7 @@
<script lang="ts">
import { defineComponent } from 'vue';
import * as tinycolor from 'tinycolor2';
import tinycolor from 'tinycolor2';
import { toUnicode } from 'punycode';
import { host as localHost } from '@/config';
import { $i } from '@/account';

View file

@ -23,7 +23,7 @@
<script lang="ts">
import { defineComponent } from 'vue';
import * as tinycolor from 'tinycolor2';
import tinycolor from 'tinycolor2';
const localStoragePrefix = 'ui:folder:';

View file

@ -15,7 +15,7 @@ if (localStorage.getItem('accounts') != null) {
import { computed, createApp, watch, markRaw, version as vueVersion } from 'vue';
import compareVersions from 'compare-versions';
import * as JSON5 from 'json5';
import JSON5 from 'json5';
import widgets from '@/widgets';
import directives from '@/directives';

View file

@ -27,7 +27,7 @@
<script lang="ts">
import { defineComponent } from 'vue';
import * as JSON5 from 'json5';
import JSON5 from 'json5';
import MkButton from '@/components/ui/button.vue';
import MkInput from '@/components/form/input.vue';
import MkTextarea from '@/components/form/textarea.vue';

View file

@ -35,7 +35,7 @@
<script lang="ts">
import { defineComponent } from 'vue';
import * as tinycolor from 'tinycolor2';
import tinycolor from 'tinycolor2';
import FormLink from '@/components/form/link.vue';
import FormSwitch from '@/components/form/switch.vue';
import FormSection from '@/components/form/section.vue';

View file

@ -13,7 +13,7 @@
<script lang="ts" setup>
import { } from 'vue';
import * as JSON5 from 'json5';
import JSON5 from 'json5';
import FormTextarea from '@/components/form/textarea.vue';
import FormButton from '@/components/ui/button.vue';
import { applyTheme, validateTheme } from '@/scripts/theme';

View file

@ -27,7 +27,7 @@
<script lang="ts">
import { defineComponent } from 'vue';
import * as JSON5 from 'json5';
import JSON5 from 'json5';
import FormTextarea from '@/components/form/textarea.vue';
import FormSelect from '@/components/form/select.vue';
import FormInput from '@/components/form/input.vue';

View file

@ -87,7 +87,7 @@
<script lang="ts">
import { computed, defineComponent, onActivated, onMounted, ref, watch } from 'vue';
import * as JSON5 from 'json5';
import JSON5 from 'json5';
import FormSwitch from '@/components/form/switch.vue';
import FormSelect from '@/components/form/select.vue';
import FormGroup from '@/components/form/group.vue';

View file

@ -67,9 +67,9 @@
<script lang="ts" setup>
import { watch } from 'vue';
import { toUnicode } from 'punycode/';
import * as tinycolor from 'tinycolor2';
import tinycolor from 'tinycolor2';
import { v4 as uuid} from 'uuid';
import * as JSON5 from 'json5';
import JSON5 from 'json5';
import FormButton from '@/components/ui/button.vue';
import FormTextarea from '@/components/form/textarea.vue';

View file

@ -1,5 +1,5 @@
import { nextTick, Ref, ref } from 'vue';
import * as getCaretCoordinates from 'textarea-caret';
import getCaretCoordinates from 'textarea-caret';
import { toASCII } from 'punycode/';
import { popup } from '@/os';

View file

@ -1,9 +1,9 @@
import * as tinycolor from 'tinycolor2';
import tinycolor from 'tinycolor2';
import { Hpml } from './evaluator';
import { values, utils } from '@syuilo/aiscript';
import { Fn, HpmlScope } from '.';
import { Expr } from './expr';
import * as seedrandom from 'seedrandom';
import seedrandom from 'seedrandom';
/* TODO: https://www.chartjs.org/docs/latest/configuration/canvas-background.html#color
// https://stackoverflow.com/questions/38493564/chart-area-background-color-chartjs

View file

@ -1,5 +1,5 @@
import { globalEvents } from '@/events';
import * as tinycolor from 'tinycolor2';
import tinycolor from 'tinycolor2';
export type Theme = {
id: string;