first commit

This commit is contained in:
2025-12-29 14:59:44 +08:00
commit 10c3fbb0d7
5315 changed files with 795443 additions and 0 deletions

View File

@@ -0,0 +1,43 @@
import { type PropType, type ExtractPropTypes } from 'vue';
import { ButtonType } from '../button';
export declare const actionBarButtonProps: {
to: PropType<import("vue-router").RouteLocationRaw>;
url: StringConstructor;
replace: BooleanConstructor;
} & {
type: PropType<ButtonType>;
text: StringConstructor;
icon: StringConstructor;
color: StringConstructor;
loading: BooleanConstructor;
disabled: BooleanConstructor;
};
export type ActionBarButtonProps = ExtractPropTypes<typeof actionBarButtonProps>;
declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
to: PropType<import("vue-router").RouteLocationRaw>;
url: StringConstructor;
replace: BooleanConstructor;
} & {
type: PropType<ButtonType>;
text: StringConstructor;
icon: StringConstructor;
color: StringConstructor;
loading: BooleanConstructor;
disabled: BooleanConstructor;
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<ExtractPropTypes<{
to: PropType<import("vue-router").RouteLocationRaw>;
url: StringConstructor;
replace: BooleanConstructor;
} & {
type: PropType<ButtonType>;
text: StringConstructor;
icon: StringConstructor;
color: StringConstructor;
loading: BooleanConstructor;
disabled: BooleanConstructor;
}>> & Readonly<{}>, {
replace: boolean;
disabled: boolean;
loading: boolean;
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
export default _default;

View File

@@ -0,0 +1,73 @@
import { computed, defineComponent, createVNode as _createVNode } from "vue";
import { extend, createNamespace } from "../utils/index.mjs";
import { ACTION_BAR_KEY } from "../action-bar/ActionBar.mjs";
import { useParent } from "@vant/use";
import { useExpose } from "../composables/use-expose.mjs";
import { useRoute, routeProps } from "../composables/use-route.mjs";
import { Button } from "../button/index.mjs";
const [name, bem] = createNamespace("action-bar-button");
const actionBarButtonProps = extend({}, routeProps, {
type: String,
text: String,
icon: String,
color: String,
loading: Boolean,
disabled: Boolean
});
var stdin_default = defineComponent({
name,
props: actionBarButtonProps,
setup(props, {
slots
}) {
const route = useRoute();
const {
parent,
index
} = useParent(ACTION_BAR_KEY);
const isFirst = computed(() => {
if (parent) {
const prev = parent.children[index.value - 1];
return !(prev && "isButton" in prev);
}
});
const isLast = computed(() => {
if (parent) {
const next = parent.children[index.value + 1];
return !(next && "isButton" in next);
}
});
useExpose({
isButton: true
});
return () => {
const {
type,
icon,
text,
color,
loading,
disabled
} = props;
return _createVNode(Button, {
"class": bem([type, {
last: isLast.value,
first: isFirst.value
}]),
"size": "large",
"type": type,
"icon": icon,
"color": color,
"loading": loading,
"disabled": disabled,
"onClick": route
}, {
default: () => [slots.default ? slots.default() : text]
});
};
}
});
export {
actionBarButtonProps,
stdin_default as default
};

1
node_modules/vant/es/action-bar-button/index.css generated vendored Normal file
View File

@@ -0,0 +1 @@
:root,:host{--van-action-bar-button-height: 40px;--van-action-bar-button-warning-color: var(--van-gradient-orange);--van-action-bar-button-danger-color: var(--van-gradient-red)}.van-action-bar-button{flex:1;height:var(--van-action-bar-button-height);font-weight:var(--van-font-bold);font-size:var(--van-font-size-md);border:none;border-radius:0}.van-action-bar-button--first{margin-left:5px;border-top-left-radius:var(--van-radius-max);border-bottom-left-radius:var(--van-radius-max)}.van-action-bar-button--last{margin-right:5px;border-top-right-radius:var(--van-radius-max);border-bottom-right-radius:var(--van-radius-max)}.van-action-bar-button--warning{background:var(--van-action-bar-button-warning-color)}.van-action-bar-button--danger{background:var(--van-action-bar-button-danger-color)}@media (max-width: 321px){.van-action-bar-button{font-size:13px}}

36
node_modules/vant/es/action-bar-button/index.d.ts generated vendored Normal file
View File

@@ -0,0 +1,36 @@
export declare const ActionBarButton: import("../utils").WithInstall<import("vue").DefineComponent<import("vue").ExtractPropTypes<{
to: import("vue").PropType<import("vue-router").RouteLocationRaw>;
url: StringConstructor;
replace: BooleanConstructor;
} & {
type: import("vue").PropType<import("..").ButtonType>;
text: StringConstructor;
icon: StringConstructor;
color: StringConstructor;
loading: BooleanConstructor;
disabled: BooleanConstructor;
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
to: import("vue").PropType<import("vue-router").RouteLocationRaw>;
url: StringConstructor;
replace: BooleanConstructor;
} & {
type: import("vue").PropType<import("..").ButtonType>;
text: StringConstructor;
icon: StringConstructor;
color: StringConstructor;
loading: BooleanConstructor;
disabled: BooleanConstructor;
}>> & Readonly<{}>, {
replace: boolean;
disabled: boolean;
loading: boolean;
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>>;
export default ActionBarButton;
export { actionBarButtonProps } from './ActionBarButton';
export type { ActionBarButtonProps } from './ActionBarButton';
export type { ActionBarButtonThemeVars } from './types';
declare module 'vue' {
interface GlobalComponents {
VanActionBarButton: typeof ActionBarButton;
}
}

10
node_modules/vant/es/action-bar-button/index.mjs generated vendored Normal file
View File

@@ -0,0 +1,10 @@
import { withInstall } from "../utils/index.mjs";
import _ActionBarButton from "./ActionBarButton.mjs";
const ActionBarButton = withInstall(_ActionBarButton);
var stdin_default = ActionBarButton;
import { actionBarButtonProps } from "./ActionBarButton.mjs";
export {
ActionBarButton,
actionBarButtonProps,
stdin_default as default
};

View File

@@ -0,0 +1 @@
export {};

View File

@@ -0,0 +1,7 @@
import "../../style/base.css";
import "../../action-bar/index.css";
import "../../badge/index.css";
import "../../icon/index.css";
import "../../loading/index.css";
import "../../button/index.css";
import "../index.css";

5
node_modules/vant/es/action-bar-button/types.d.ts generated vendored Normal file
View File

@@ -0,0 +1,5 @@
export type ActionBarButtonThemeVars = {
actionBarButtonHeight?: string;
actionBarButtonWarningColor?: string;
actionBarButtonDangerColor?: string;
};

0
node_modules/vant/es/action-bar-button/types.mjs generated vendored Normal file
View File