feat!: publish per-component ESM entries as @timi/tdesign-mobile

This commit is contained in:
Timi
2026-11-23 20:28:05 +08:00
parent 7349bb3429
commit 3f4c98fbf3
44 changed files with 137 additions and 81 deletions
+1 -1
View File
@@ -84,7 +84,7 @@
<script setup lang="ts">
import { nextTick, useTemplateRef } from "vue";
import { MarkdownView } from "timi-web";
import { MarkdownView } from "@timi/web/components/markdown-view";
import AiChatThinking from "./AiChatThinking.vue";
import type {
AiChatMessage,
+1 -1
View File
@@ -1,4 +1,4 @@
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
import AiChatComposerView from "./AiChatComposer.vue";
import AiChatMessageListView from "./AiChatMessageList.vue";
import AiChatPanelView from "./AiChatPanel.vue";
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const AppShell = WebToolkit.withInstall(view);
export default AppShell;
+1 -1
View File
@@ -3,7 +3,7 @@ import {
TEMP_FILE_ID_ATTR,
isLocalMediaId,
normalizeContent
} from "timi-web/editor";
} from "@timi/web/editor";
import type { ArticleContentType, Attachment } from "./types";
/** 文章内容中附件和临时文件的标识前缀。 */
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
import type { Article } from "./types";
export type {
+2 -2
View File
@@ -25,7 +25,7 @@
<script lang="ts" setup>
import type { Article, ArticleContentType, Attachment, UploadResult } from "./types";
import { MarkdownEditor } from "timi-web";
import { MarkdownEditor } from "@timi/web/components/markdown-editor";
import { TiptapEditor } from "../tiptap-editor";
import type { TiptapEditorExpose } from "../tiptap-editor";
import {
@@ -41,7 +41,7 @@ import {
ATTACHMENT_ID_ATTR,
TEMP_FILE_ID_ATTR,
normalizeContent
} from "timi-web/editor";
} from "@timi/web/editor";
defineOptions({
name: "ArticleEditor"
+1 -1
View File
@@ -1,4 +1,4 @@
import type { UploadResult as EditorUploadResult } from "timi-web/editor";
import type { UploadResult as EditorUploadResult } from "@timi/web/editor";
/** 文章编辑器支持的正文类型。 */
export type ArticleContentType = "TEXT" | "MARKDOWN" | "TIP_TAP";
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const ArticleView = WebToolkit.withInstall(view);
export default ArticleView;
+2 -2
View File
@@ -14,14 +14,14 @@
<script lang="ts" setup>
import type { Article, Attachment } from "../article-editor/types";
import { MarkdownView } from "timi-web";
import { MarkdownView } from "@timi/web/components/markdown-view";
import { TiptapView } from "../tiptap-view";
import {
getAttachmentIdFromSrc,
normalizeArticleContentType,
normalizeRawArticleContent
} from "../article-editor/content";
import { ATTACHMENT_ID_ATTR, normalizeContent } from "timi-web/editor";
import { ATTACHMENT_ID_ATTR, normalizeContent } from "@timi/web/editor";
defineOptions({
name: "ArticleView"
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export type {
AttachmentSelectorItem,
+1 -1
View File
@@ -63,7 +63,7 @@ import type {
AttachmentSelectorViewerItem
} from "./types";
import { getMediaKind, getMediaPreviewURL } from "./utils";
import { CenterTips } from "timi-web";
import { CenterTips } from "@timi/web/components/center-tips";
defineOptions({
name: "AttachmentSelector",
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const BottomPopup = WebToolkit.withInstall(view);
export default BottomPopup;
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const CardContainer = WebToolkit.withInstall(view);
export default CardContainer;
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
import "./style.less";
export type CodeEditorScrollState = {
+2 -2
View File
@@ -65,8 +65,8 @@ import {
replaceMatchText,
type TextSearchMatch,
type TextSearchOptions
} from "timi-web/editor";
import { highlightCode, resolveCodeEditorKeydown, resolvePrismLanguage } from "timi-web/editor";
} from "@timi/web/editor";
import { highlightCode, resolveCodeEditorKeydown, resolvePrismLanguage } from "@timi/web/editor";
defineOptions({
name: "CodeEditor"
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const DropdownFilter = WebToolkit.withInstall(view);
export default DropdownFilter;
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const DurationPicker = WebToolkit.withInstall(view);
export default DurationPicker;
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const MasterDetailPage = WebToolkit.withInstall(view);
export default MasterDetailPage;
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const MasterDetail = WebToolkit.withInstall(view);
export default MasterDetail;
+1 -1
View File
@@ -31,7 +31,7 @@
<script setup lang="ts">
import { computed, type StyleValue } from "vue";
import { CenterTips } from "timi-web";
import { CenterTips } from "@timi/web/components/center-tips";
import { useLayout } from "../../composables/use-layout";
import type { MasterDetailProps } from "./type";
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
import type { NotifyDetail } from "./types";
export type { NotifyContentType, NotifyDetail } from "./types";
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const NotifyView = WebToolkit.withInstall(view);
export default NotifyView;
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export type {
PageTransitionBackground,
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const PaneTransition = WebToolkit.withInstall(view);
export default PaneTransition;
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const RootLayout = WebToolkit.withInstall(view);
export default RootLayout;
+1 -1
View File
@@ -6,7 +6,7 @@
</template>
<script lang="ts" setup>
import { Copyright } from "timi-web";
import { Copyright } from "@timi/web/components/copyright";
defineOptions({
name: "RootLayout"
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export type {
SpaceAlign,
+1 -1
View File
@@ -1,4 +1,4 @@
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
import timeline from "./index.vue";
import item from "./item.vue";
@@ -21,8 +21,8 @@
<script lang="ts" setup>
import type { PickerValue } from "tdesign-mobile-vue";
import { supportedCodeLanguages } from "timi-web/editor";
import type { TiptapEditorInstance } from "timi-web/editor";
import { supportedCodeLanguages } from "@timi/web/editor";
import type { TiptapEditorInstance } from "@timi/web/editor";
defineOptions({
name: "TiptapCodeBlockButton"
@@ -60,7 +60,7 @@
<script lang="ts" setup>
import { showPlatformMessage } from "../message";
import type { TiptapEditorInstance } from "timi-web/editor";
import type { TiptapEditorInstance } from "@timi/web/editor";
import BottomPopup from "../bottom-popup/index.vue";
defineOptions({
@@ -35,7 +35,7 @@
</template>
<script lang="ts" setup>
import type { TiptapEditorInstance } from "timi-web/editor";
import type { TiptapEditorInstance } from "@timi/web/editor";
import BottomPopup from "../bottom-popup/index.vue";
defineOptions({
@@ -90,7 +90,7 @@
<script lang="ts" setup>
import { showPlatformMessage } from "../message";
import type { TiptapEditorInstance, UploadResult } from "timi-web/editor";
import type { TiptapEditorInstance, UploadResult } from "@timi/web/editor";
import BottomPopup from "../bottom-popup/index.vue";
defineOptions({
@@ -61,8 +61,8 @@
</template>
<script lang="ts" setup>
import { TABLE_PICKER_SIZE } from "timi-web/editor";
import type { TiptapEditorInstance } from "timi-web/editor";
import { TABLE_PICKER_SIZE } from "@timi/web/editor";
import type { TiptapEditorInstance } from "@timi/web/editor";
import BottomPopup from "../bottom-popup/index.vue";
defineOptions({
@@ -151,8 +151,8 @@
<script lang="ts" setup>
import type { ColorObject } from "tdesign-mobile-vue";
import type { AlignType, UploadResult, TiptapEditorInstance } from "timi-web/editor";
import { headingMeta } from "timi-web/editor";
import type { AlignType, UploadResult, TiptapEditorInstance } from "@timi/web/editor";
import { headingMeta } from "@timi/web/editor";
import TiptapCodeBlockButton from "./TiptapCodeBlockButton.vue";
import TiptapIframeButton from "./TiptapIframeButton.vue";
import TiptapLinkButton from "./TiptapLinkButton.vue";
+3 -3
View File
@@ -1,8 +1,8 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import type { TiptapEditorInstance } from "timi-web/editor";
import { WebToolkit } from "@timi/web/utils";
import type { TiptapEditorInstance } from "@timi/web/editor";
export * from "timi-web/editor";
export * from "@timi/web/editor";
export type TiptapEditorExpose = {
submit: () => Promise<string>;
getPendingMediaCount: () => number;
+5 -5
View File
@@ -58,18 +58,18 @@ import {
buildSearchRegex,
replaceMatchText,
type TextSearchOptions
} from "timi-web/editor";
import { Toolkit } from "timi-web";
import type { PendingMediaItem, UploadMediaType, UploadResult } from "timi-web/editor";
} from "@timi/web/editor";
import { Toolkit } from "@timi/web/utils";
import type { PendingMediaItem, UploadMediaType, UploadResult } from "@timi/web/editor";
import TiptapToolbar from "./TiptapToolbar.vue";
import { useTiptapEditor } from "timi-web/editor";
import { useTiptapEditor } from "@timi/web/editor";
import {
ATTACHMENT_ID_ATTR,
LOCAL_MEDIA_ID_PREFIX,
TEMP_FILE_ID_ATTR,
isLocalMediaId,
normalizeContent
} from "timi-web/editor";
} from "@timi/web/editor";
defineOptions({
name: "TiptapEditor"
+1 -1
View File
@@ -1,5 +1,5 @@
import view from "./index.vue";
import { WebToolkit } from "timi-web";
import { WebToolkit } from "@timi/web/utils";
export const TiptapView = WebToolkit.withInstall(view);
export default TiptapView;
+1 -1
View File
@@ -10,7 +10,7 @@
</template>
<script lang="ts" setup>
import { normalizeContent, useTiptapView } from "timi-web/editor";
import { normalizeContent, useTiptapView } from "@timi/web/editor";
defineOptions({
name: "TiptapView"