@maizzle/framework 6.0.0-9 → 6.0.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/maizzle.mjs +10 -0
- package/dist/build.d.mts +19 -0
- package/dist/build.d.mts.map +1 -0
- package/dist/build.mjs +121 -0
- package/dist/build.mjs.map +1 -0
- package/dist/components/Button.vue +141 -0
- package/dist/components/Divider.vue +105 -0
- package/dist/components/NoWidows.vue +123 -0
- package/dist/components/NotOutlook.vue +17 -0
- package/dist/components/Outlook.vue +74 -0
- package/dist/components/Spacer.vue +36 -0
- package/dist/components/Vml.vue +89 -0
- package/dist/components/WithUrl.vue +190 -0
- package/dist/components/utils.d.mts +5 -0
- package/dist/components/utils.d.mts.map +1 -0
- package/dist/components/utils.mjs +9 -0
- package/dist/components/utils.mjs.map +1 -0
- package/dist/components/utils.ts +6 -0
- package/dist/composables/defineConfig.d.mts +14 -0
- package/dist/composables/defineConfig.d.mts.map +1 -0
- package/dist/composables/defineConfig.mjs +34 -0
- package/dist/composables/defineConfig.mjs.map +1 -0
- package/dist/composables/renderContext.d.mts +19 -0
- package/dist/composables/renderContext.d.mts.map +1 -0
- package/dist/composables/renderContext.mjs +6 -0
- package/dist/composables/renderContext.mjs.map +1 -0
- package/dist/composables/useConfig.d.mts +9 -0
- package/dist/composables/useConfig.d.mts.map +1 -0
- package/dist/composables/useConfig.mjs +13 -0
- package/dist/composables/useConfig.mjs.map +1 -0
- package/dist/composables/useDoctype.d.mts +13 -0
- package/dist/composables/useDoctype.d.mts.map +1 -0
- package/dist/composables/useDoctype.mjs +20 -0
- package/dist/composables/useDoctype.mjs.map +1 -0
- package/dist/composables/useEvent.d.mts +17 -0
- package/dist/composables/useEvent.d.mts.map +1 -0
- package/dist/composables/useEvent.mjs +25 -0
- package/dist/composables/useEvent.mjs.map +1 -0
- package/dist/composables/usePlaintext.d.mts +19 -0
- package/dist/composables/usePlaintext.d.mts.map +1 -0
- package/dist/composables/usePlaintext.mjs +22 -0
- package/dist/composables/usePlaintext.mjs.map +1 -0
- package/dist/config/defaults.d.mts +6 -0
- package/dist/config/defaults.d.mts.map +1 -0
- package/dist/config/defaults.mjs +28 -0
- package/dist/config/defaults.mjs.map +1 -0
- package/dist/config/index.d.mts +15 -0
- package/dist/config/index.d.mts.map +1 -0
- package/dist/config/index.mjs +47 -0
- package/dist/config/index.mjs.map +1 -0
- package/dist/events/index.d.mts +91 -0
- package/dist/events/index.d.mts.map +1 -0
- package/dist/events/index.mjs +110 -0
- package/dist/events/index.mjs.map +1 -0
- package/dist/index.d.mts +29 -0
- package/dist/index.mjs +29 -0
- package/dist/plaintext.d.mts +5 -0
- package/dist/plaintext.d.mts.map +1 -0
- package/dist/plaintext.mjs +15 -0
- package/dist/plaintext.mjs.map +1 -0
- package/dist/plugin.d.mts +17 -0
- package/dist/plugin.d.mts.map +1 -0
- package/dist/plugin.mjs +41 -0
- package/dist/plugin.mjs.map +1 -0
- package/dist/plugins/postcss/mergeMediaQueries.d.mts +18 -0
- package/dist/plugins/postcss/mergeMediaQueries.d.mts.map +1 -0
- package/dist/plugins/postcss/mergeMediaQueries.mjs +22 -0
- package/dist/plugins/postcss/mergeMediaQueries.mjs.map +1 -0
- package/dist/plugins/postcss/pruneVars.d.mts +8 -0
- package/dist/plugins/postcss/pruneVars.d.mts.map +1 -0
- package/dist/plugins/postcss/pruneVars.mjs +49 -0
- package/dist/plugins/postcss/pruneVars.mjs.map +1 -0
- package/dist/plugins/postcss/removeDeclarations.d.mts +12 -0
- package/dist/plugins/postcss/removeDeclarations.d.mts.map +1 -0
- package/dist/plugins/postcss/removeDeclarations.mjs +45 -0
- package/dist/plugins/postcss/removeDeclarations.mjs.map +1 -0
- package/dist/plugins/postcss/tailwindCleanup.d.mts +18 -0
- package/dist/plugins/postcss/tailwindCleanup.d.mts.map +1 -0
- package/dist/plugins/postcss/tailwindCleanup.mjs +35 -0
- package/dist/plugins/postcss/tailwindCleanup.mjs.map +1 -0
- package/dist/render/createRenderer.d.mts +34 -0
- package/dist/render/createRenderer.d.mts.map +1 -0
- package/dist/render/createRenderer.mjs +149 -0
- package/dist/render/createRenderer.mjs.map +1 -0
- package/dist/render/index.d.mts +26 -0
- package/dist/render/index.d.mts.map +1 -0
- package/dist/render/index.mjs +40 -0
- package/dist/render/index.mjs.map +1 -0
- package/dist/serve.d.mts +25 -0
- package/dist/serve.d.mts.map +1 -0
- package/dist/serve.mjs +402 -0
- package/dist/serve.mjs.map +1 -0
- package/dist/server/compatibility.d.mts +6 -0
- package/dist/server/compatibility.d.mts.map +1 -0
- package/dist/server/compatibility.mjs +83 -0
- package/dist/server/compatibility.mjs.map +1 -0
- package/dist/server/linter.d.mts +6 -0
- package/dist/server/linter.d.mts.map +1 -0
- package/dist/server/linter.mjs +200 -0
- package/dist/server/linter.mjs.map +1 -0
- package/dist/server/ui/App.vue +360 -0
- package/dist/server/ui/components/ui/button/Button.vue +31 -0
- package/dist/server/ui/components/ui/button/index.ts +38 -0
- package/dist/server/ui/components/ui/command/Command.vue +87 -0
- package/dist/server/ui/components/ui/command/CommandDialog.vue +31 -0
- package/dist/server/ui/components/ui/command/CommandEmpty.vue +27 -0
- package/dist/server/ui/components/ui/command/CommandGroup.vue +45 -0
- package/dist/server/ui/components/ui/command/CommandInput.vue +39 -0
- package/dist/server/ui/components/ui/command/CommandItem.vue +76 -0
- package/dist/server/ui/components/ui/command/CommandList.vue +25 -0
- package/dist/server/ui/components/ui/command/CommandSeparator.vue +21 -0
- package/dist/server/ui/components/ui/command/CommandShortcut.vue +17 -0
- package/dist/server/ui/components/ui/command/index.ts +25 -0
- package/dist/server/ui/components/ui/dialog/Dialog.vue +19 -0
- package/dist/server/ui/components/ui/dialog/DialogClose.vue +15 -0
- package/dist/server/ui/components/ui/dialog/DialogContent.vue +53 -0
- package/dist/server/ui/components/ui/dialog/DialogDescription.vue +23 -0
- package/dist/server/ui/components/ui/dialog/DialogFooter.vue +27 -0
- package/dist/server/ui/components/ui/dialog/DialogHeader.vue +17 -0
- package/dist/server/ui/components/ui/dialog/DialogOverlay.vue +21 -0
- package/dist/server/ui/components/ui/dialog/DialogScrollContent.vue +59 -0
- package/dist/server/ui/components/ui/dialog/DialogTitle.vue +23 -0
- package/dist/server/ui/components/ui/dialog/DialogTrigger.vue +15 -0
- package/dist/server/ui/components/ui/dialog/index.ts +10 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenu.vue +19 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuCheckboxItem.vue +39 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuContent.vue +39 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuGroup.vue +15 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuItem.vue +31 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuLabel.vue +23 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuRadioGroup.vue +21 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuRadioItem.vue +40 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuSeparator.vue +23 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuShortcut.vue +17 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuSub.vue +18 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuSubContent.vue +27 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuSubTrigger.vue +31 -0
- package/dist/server/ui/components/ui/dropdown-menu/DropdownMenuTrigger.vue +17 -0
- package/dist/server/ui/components/ui/dropdown-menu/index.ts +16 -0
- package/dist/server/ui/components/ui/empty/Empty.vue +20 -0
- package/dist/server/ui/components/ui/empty/EmptyContent.vue +20 -0
- package/dist/server/ui/components/ui/empty/EmptyDescription.vue +20 -0
- package/dist/server/ui/components/ui/empty/EmptyHeader.vue +20 -0
- package/dist/server/ui/components/ui/empty/EmptyMedia.vue +21 -0
- package/dist/server/ui/components/ui/empty/EmptyTitle.vue +17 -0
- package/dist/server/ui/components/ui/empty/index.ts +26 -0
- package/dist/server/ui/components/ui/input/Input.vue +33 -0
- package/dist/server/ui/components/ui/input/index.ts +1 -0
- package/dist/server/ui/components/ui/kbd/Kbd.vue +20 -0
- package/dist/server/ui/components/ui/kbd/KbdGroup.vue +17 -0
- package/dist/server/ui/components/ui/kbd/index.ts +2 -0
- package/dist/server/ui/components/ui/resizable/ResizableHandle.vue +30 -0
- package/dist/server/ui/components/ui/resizable/ResizablePanel.vue +21 -0
- package/dist/server/ui/components/ui/resizable/ResizablePanelGroup.vue +25 -0
- package/dist/server/ui/components/ui/resizable/index.ts +3 -0
- package/dist/server/ui/components/ui/scroll-area/ScrollArea.vue +33 -0
- package/dist/server/ui/components/ui/scroll-area/ScrollBar.vue +32 -0
- package/dist/server/ui/components/ui/scroll-area/index.ts +2 -0
- package/dist/server/ui/components/ui/separator/Separator.vue +29 -0
- package/dist/server/ui/components/ui/separator/index.ts +1 -0
- package/dist/server/ui/components/ui/sheet/Sheet.vue +19 -0
- package/dist/server/ui/components/ui/sheet/SheetClose.vue +15 -0
- package/dist/server/ui/components/ui/sheet/SheetContent.vue +62 -0
- package/dist/server/ui/components/ui/sheet/SheetDescription.vue +21 -0
- package/dist/server/ui/components/ui/sheet/SheetFooter.vue +16 -0
- package/dist/server/ui/components/ui/sheet/SheetHeader.vue +15 -0
- package/dist/server/ui/components/ui/sheet/SheetOverlay.vue +21 -0
- package/dist/server/ui/components/ui/sheet/SheetTitle.vue +21 -0
- package/dist/server/ui/components/ui/sheet/SheetTrigger.vue +15 -0
- package/dist/server/ui/components/ui/sheet/index.ts +8 -0
- package/dist/server/ui/components/ui/sidebar/Sidebar.vue +96 -0
- package/dist/server/ui/components/ui/sidebar/SidebarContent.vue +18 -0
- package/dist/server/ui/components/ui/sidebar/SidebarFooter.vue +18 -0
- package/dist/server/ui/components/ui/sidebar/SidebarGroup.vue +18 -0
- package/dist/server/ui/components/ui/sidebar/SidebarGroupAction.vue +27 -0
- package/dist/server/ui/components/ui/sidebar/SidebarGroupContent.vue +18 -0
- package/dist/server/ui/components/ui/sidebar/SidebarGroupLabel.vue +25 -0
- package/dist/server/ui/components/ui/sidebar/SidebarHeader.vue +18 -0
- package/dist/server/ui/components/ui/sidebar/SidebarInput.vue +31 -0
- package/dist/server/ui/components/ui/sidebar/SidebarInset.vue +21 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenu.vue +18 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuAction.vue +35 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuBadge.vue +26 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuButton.vue +48 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuButtonChild.vue +36 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuItem.vue +18 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuSkeleton.vue +35 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuSub.vue +22 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuSubButton.vue +36 -0
- package/dist/server/ui/components/ui/sidebar/SidebarMenuSubItem.vue +18 -0
- package/dist/server/ui/components/ui/sidebar/SidebarProvider.vue +82 -0
- package/dist/server/ui/components/ui/sidebar/SidebarRail.vue +33 -0
- package/dist/server/ui/components/ui/sidebar/SidebarSeparator.vue +19 -0
- package/dist/server/ui/components/ui/sidebar/SidebarTrigger.vue +28 -0
- package/dist/server/ui/components/ui/sidebar/index.ts +60 -0
- package/dist/server/ui/components/ui/sidebar/utils.ts +19 -0
- package/dist/server/ui/components/ui/skeleton/Skeleton.vue +17 -0
- package/dist/server/ui/components/ui/skeleton/index.ts +1 -0
- package/dist/server/ui/components/ui/tabs/Tabs.vue +24 -0
- package/dist/server/ui/components/ui/tabs/TabsContent.vue +21 -0
- package/dist/server/ui/components/ui/tabs/TabsList.vue +24 -0
- package/dist/server/ui/components/ui/tabs/TabsTrigger.vue +26 -0
- package/dist/server/ui/components/ui/tabs/index.ts +4 -0
- package/dist/server/ui/components/ui/toggle/Toggle.vue +35 -0
- package/dist/server/ui/components/ui/toggle/index.ts +28 -0
- package/dist/server/ui/components/ui/toggle-group/ToggleGroup.vue +49 -0
- package/dist/server/ui/components/ui/toggle-group/ToggleGroupItem.vue +46 -0
- package/dist/server/ui/components/ui/toggle-group/index.ts +2 -0
- package/dist/server/ui/components/ui/tooltip/Tooltip.vue +19 -0
- package/dist/server/ui/components/ui/tooltip/TooltipContent.vue +34 -0
- package/dist/server/ui/components/ui/tooltip/TooltipProvider.vue +14 -0
- package/dist/server/ui/components/ui/tooltip/TooltipTrigger.vue +15 -0
- package/dist/server/ui/components/ui/tooltip/index.ts +4 -0
- package/dist/server/ui/favicon.svg +1 -0
- package/dist/server/ui/index.html +13 -0
- package/dist/server/ui/lib/utils.ts +7 -0
- package/dist/server/ui/logo-gradient.svg +1 -0
- package/dist/server/ui/logo.svg +1 -0
- package/dist/server/ui/main.css +129 -0
- package/dist/server/ui/main.ts +16 -0
- package/dist/server/ui/mark-gradient.svg +1 -0
- package/dist/server/ui/mark.svg +1 -0
- package/dist/server/ui/pages/Home.vue +39 -0
- package/dist/server/ui/pages/Preview.vue +609 -0
- package/dist/server/ui/stripes.svg +174 -0
- package/dist/transformers/addAttributes.d.mts +32 -0
- package/dist/transformers/addAttributes.d.mts.map +1 -0
- package/dist/transformers/addAttributes.mjs +101 -0
- package/dist/transformers/addAttributes.mjs.map +1 -0
- package/dist/transformers/attributeToStyle.d.mts +25 -0
- package/dist/transformers/attributeToStyle.d.mts.map +1 -0
- package/dist/transformers/attributeToStyle.mjs +80 -0
- package/dist/transformers/attributeToStyle.mjs.map +1 -0
- package/dist/transformers/base.d.mts +8 -0
- package/dist/transformers/base.d.mts.map +1 -0
- package/dist/transformers/base.mjs +160 -0
- package/dist/transformers/base.mjs.map +1 -0
- package/dist/transformers/entities.d.mts +8 -0
- package/dist/transformers/entities.d.mts.map +1 -0
- package/dist/transformers/entities.mjs +38 -0
- package/dist/transformers/entities.mjs.map +1 -0
- package/dist/transformers/format.d.mts +15 -0
- package/dist/transformers/format.d.mts.map +1 -0
- package/dist/transformers/format.mjs +26 -0
- package/dist/transformers/format.mjs.map +1 -0
- package/dist/transformers/index.d.mts +35 -0
- package/dist/transformers/index.d.mts.map +1 -0
- package/dist/transformers/index.mjs +73 -0
- package/dist/transformers/index.mjs.map +1 -0
- package/dist/transformers/inlineCSS.d.mts +30 -0
- package/dist/transformers/inlineCSS.d.mts.map +1 -0
- package/dist/transformers/inlineCSS.mjs +79 -0
- package/dist/transformers/inlineCSS.mjs.map +1 -0
- package/dist/transformers/inlineLink.d.mts +14 -0
- package/dist/transformers/inlineLink.d.mts.map +1 -0
- package/dist/transformers/inlineLink.mjs +76 -0
- package/dist/transformers/inlineLink.mjs.map +1 -0
- package/dist/transformers/minify.d.mts +17 -0
- package/dist/transformers/minify.d.mts.map +1 -0
- package/dist/transformers/minify.mjs +24 -0
- package/dist/transformers/minify.mjs.map +1 -0
- package/dist/transformers/purgeCSS.d.mts +23 -0
- package/dist/transformers/purgeCSS.d.mts.map +1 -0
- package/dist/transformers/purgeCSS.mjs +66 -0
- package/dist/transformers/purgeCSS.mjs.map +1 -0
- package/dist/transformers/removeAttributes.d.mts +31 -0
- package/dist/transformers/removeAttributes.d.mts.map +1 -0
- package/dist/transformers/removeAttributes.mjs +63 -0
- package/dist/transformers/removeAttributes.mjs.map +1 -0
- package/dist/transformers/replaceStrings.d.mts +16 -0
- package/dist/transformers/replaceStrings.d.mts.map +1 -0
- package/dist/transformers/replaceStrings.mjs +19 -0
- package/dist/transformers/replaceStrings.mjs.map +1 -0
- package/dist/transformers/safeClassNames.d.mts +22 -0
- package/dist/transformers/safeClassNames.d.mts.map +1 -0
- package/dist/transformers/safeClassNames.mjs +103 -0
- package/dist/transformers/safeClassNames.mjs.map +1 -0
- package/dist/transformers/shorthandCSS.d.mts +24 -0
- package/dist/transformers/shorthandCSS.d.mts.map +1 -0
- package/dist/transformers/shorthandCSS.mjs +48 -0
- package/dist/transformers/shorthandCSS.mjs.map +1 -0
- package/dist/transformers/tailwindcss.d.mts +20 -0
- package/dist/transformers/tailwindcss.d.mts.map +1 -0
- package/dist/transformers/tailwindcss.mjs +136 -0
- package/dist/transformers/tailwindcss.mjs.map +1 -0
- package/dist/transformers/urlQuery.d.mts +24 -0
- package/dist/transformers/urlQuery.d.mts.map +1 -0
- package/dist/transformers/urlQuery.mjs +65 -0
- package/dist/transformers/urlQuery.mjs.map +1 -0
- package/dist/types/config.d.mts +129 -0
- package/dist/types/config.d.mts.map +1 -0
- package/dist/types/config.mjs +1 -0
- package/dist/types/index.d.mts +2 -0
- package/dist/types/index.mjs +1 -0
- package/dist/utils/ast/index.d.mts +4 -0
- package/dist/utils/ast/index.mjs +5 -0
- package/dist/utils/ast/parser.d.mts +7 -0
- package/dist/utils/ast/parser.d.mts.map +1 -0
- package/dist/utils/ast/parser.mjs +15 -0
- package/dist/utils/ast/parser.mjs.map +1 -0
- package/dist/utils/ast/serializer.d.mts +7 -0
- package/dist/utils/ast/serializer.d.mts.map +1 -0
- package/dist/utils/ast/serializer.mjs +13 -0
- package/dist/utils/ast/serializer.mjs.map +1 -0
- package/dist/utils/ast/walker.d.mts +7 -0
- package/dist/utils/ast/walker.d.mts.map +1 -0
- package/dist/utils/ast/walker.mjs +12 -0
- package/dist/utils/ast/walker.mjs.map +1 -0
- package/dist/utils/url.d.mts +8 -0
- package/dist/utils/url.d.mts.map +1 -0
- package/dist/utils/url.mjs +32 -0
- package/dist/utils/url.mjs.map +1 -0
- package/node_modules/@clack/core/CHANGELOG.md +257 -0
- package/node_modules/@clack/core/LICENSE +9 -0
- package/node_modules/@clack/core/README.md +22 -0
- package/node_modules/@clack/core/dist/index.cjs +15 -0
- package/node_modules/@clack/core/dist/index.cjs.map +1 -0
- package/node_modules/@clack/core/dist/index.d.cts +211 -0
- package/node_modules/@clack/core/dist/index.d.mts +211 -0
- package/node_modules/@clack/core/dist/index.d.ts +211 -0
- package/node_modules/@clack/core/dist/index.mjs +15 -0
- package/node_modules/@clack/core/dist/index.mjs.map +1 -0
- package/node_modules/@clack/core/package.json +62 -0
- package/node_modules/@clack/prompts/CHANGELOG.md +412 -0
- package/node_modules/@clack/prompts/LICENSE +9 -0
- package/node_modules/@clack/prompts/README.md +207 -0
- package/node_modules/@clack/prompts/dist/index.cjs +87 -0
- package/node_modules/@clack/prompts/dist/index.cjs.map +1 -0
- package/node_modules/@clack/prompts/dist/index.d.cts +165 -0
- package/node_modules/@clack/prompts/dist/index.d.mts +165 -0
- package/node_modules/@clack/prompts/dist/index.d.ts +165 -0
- package/node_modules/@clack/prompts/dist/index.mjs +87 -0
- package/node_modules/@clack/prompts/dist/index.mjs.map +1 -0
- package/node_modules/@clack/prompts/package.json +61 -0
- package/node_modules/@maizzle/cli/LICENSE +21 -0
- package/node_modules/@maizzle/cli/README.md +58 -0
- package/node_modules/@maizzle/cli/dist/commands/make/component.d.mts +4 -0
- package/node_modules/@maizzle/cli/dist/commands/make/component.mjs +31 -0
- package/node_modules/@maizzle/cli/dist/commands/make/config.d.mts +4 -0
- package/node_modules/@maizzle/cli/dist/commands/make/config.mjs +21 -0
- package/node_modules/@maizzle/cli/dist/commands/make/layout.d.mts +4 -0
- package/node_modules/@maizzle/cli/dist/commands/make/layout.mjs +31 -0
- package/node_modules/@maizzle/cli/dist/commands/make/scaffold.d.mts +5 -0
- package/node_modules/@maizzle/cli/dist/commands/make/scaffold.mjs +28 -0
- package/node_modules/@maizzle/cli/dist/commands/make/stubs/component.vue +9 -0
- package/node_modules/@maizzle/cli/dist/commands/make/stubs/config.ts +9 -0
- package/node_modules/@maizzle/cli/dist/commands/make/stubs/layout.vue +39 -0
- package/node_modules/@maizzle/cli/dist/commands/make/stubs/template.vue +8 -0
- package/node_modules/@maizzle/cli/dist/commands/make/template.d.mts +4 -0
- package/node_modules/@maizzle/cli/dist/commands/make/template.mjs +31 -0
- package/node_modules/@maizzle/cli/dist/index.d.mts +8 -0
- package/node_modules/@maizzle/cli/dist/index.mjs +42 -0
- package/node_modules/@maizzle/cli/package.json +59 -0
- package/node_modules/citty/LICENSE +36 -0
- package/node_modules/citty/README.md +134 -0
- package/node_modules/citty/dist/index.cjs +475 -0
- package/node_modules/citty/dist/index.d.cts +80 -0
- package/node_modules/citty/dist/index.d.mts +80 -0
- package/node_modules/citty/dist/index.d.ts +80 -0
- package/node_modules/citty/dist/index.mjs +463 -0
- package/node_modules/citty/package.json +49 -0
- package/node_modules/commander/LICENSE +22 -0
- package/node_modules/commander/Readme.md +1149 -0
- package/node_modules/commander/esm.mjs +16 -0
- package/node_modules/commander/index.js +24 -0
- package/node_modules/commander/lib/argument.js +149 -0
- package/node_modules/commander/lib/command.js +2662 -0
- package/node_modules/commander/lib/error.js +39 -0
- package/node_modules/commander/lib/help.js +709 -0
- package/node_modules/commander/lib/option.js +367 -0
- package/node_modules/commander/lib/suggestSimilar.js +101 -0
- package/node_modules/commander/package-support.json +16 -0
- package/node_modules/commander/package.json +82 -0
- package/node_modules/commander/typings/esm.d.mts +3 -0
- package/node_modules/commander/typings/index.d.ts +1045 -0
- package/node_modules/consola/LICENSE +47 -0
- package/node_modules/consola/README.md +352 -0
- package/node_modules/consola/basic.d.ts +1 -0
- package/node_modules/consola/browser.d.ts +1 -0
- package/node_modules/consola/core.d.ts +1 -0
- package/node_modules/consola/dist/basic.cjs +32 -0
- package/node_modules/consola/dist/basic.d.cts +23 -0
- package/node_modules/consola/dist/basic.d.mts +21 -0
- package/node_modules/consola/dist/basic.d.ts +23 -0
- package/node_modules/consola/dist/basic.mjs +24 -0
- package/node_modules/consola/dist/browser.cjs +84 -0
- package/node_modules/consola/dist/browser.d.cts +23 -0
- package/node_modules/consola/dist/browser.d.mts +21 -0
- package/node_modules/consola/dist/browser.d.ts +23 -0
- package/node_modules/consola/dist/browser.mjs +76 -0
- package/node_modules/consola/dist/chunks/prompt.cjs +288 -0
- package/node_modules/consola/dist/chunks/prompt.mjs +280 -0
- package/node_modules/consola/dist/core.cjs +517 -0
- package/node_modules/consola/dist/core.d.cts +459 -0
- package/node_modules/consola/dist/core.d.mts +459 -0
- package/node_modules/consola/dist/core.d.ts +459 -0
- package/node_modules/consola/dist/core.mjs +512 -0
- package/node_modules/consola/dist/index.cjs +663 -0
- package/node_modules/consola/dist/index.d.cts +24 -0
- package/node_modules/consola/dist/index.d.mts +22 -0
- package/node_modules/consola/dist/index.d.ts +24 -0
- package/node_modules/consola/dist/index.mjs +651 -0
- package/node_modules/consola/dist/shared/consola.DCGIlDNP.cjs +75 -0
- package/node_modules/consola/dist/shared/consola.DRwqZj3T.mjs +72 -0
- package/node_modules/consola/dist/shared/consola.DXBYu-KD.mjs +288 -0
- package/node_modules/consola/dist/shared/consola.DwRq1yyg.cjs +312 -0
- package/node_modules/consola/dist/utils.cjs +64 -0
- package/node_modules/consola/dist/utils.d.cts +286 -0
- package/node_modules/consola/dist/utils.d.mts +286 -0
- package/node_modules/consola/dist/utils.d.ts +286 -0
- package/node_modules/consola/dist/utils.mjs +54 -0
- package/node_modules/consola/lib/index.cjs +10 -0
- package/node_modules/consola/package.json +136 -0
- package/node_modules/consola/utils.d.ts +1 -0
- package/node_modules/create-maizzle/README.md +86 -0
- package/node_modules/create-maizzle/bin/create-maizzle.mjs +4 -0
- package/node_modules/create-maizzle/node_modules/@clack/core/CHANGELOG.md +340 -0
- package/node_modules/create-maizzle/node_modules/@clack/core/LICENSE +9 -0
- package/node_modules/create-maizzle/node_modules/@clack/core/README.md +22 -0
- package/node_modules/create-maizzle/node_modules/@clack/core/dist/index.d.mts +349 -0
- package/node_modules/create-maizzle/node_modules/@clack/core/dist/index.mjs +11 -0
- package/node_modules/create-maizzle/node_modules/@clack/core/dist/index.mjs.map +1 -0
- package/node_modules/create-maizzle/node_modules/@clack/core/package.json +60 -0
- package/node_modules/create-maizzle/node_modules/@clack/prompts/CHANGELOG.md +576 -0
- package/node_modules/create-maizzle/node_modules/@clack/prompts/LICENSE +9 -0
- package/node_modules/create-maizzle/node_modules/@clack/prompts/README.md +270 -0
- package/node_modules/create-maizzle/node_modules/@clack/prompts/dist/index.d.mts +391 -0
- package/node_modules/create-maizzle/node_modules/@clack/prompts/dist/index.mjs +137 -0
- package/node_modules/create-maizzle/node_modules/@clack/prompts/dist/index.mjs.map +1 -0
- package/node_modules/create-maizzle/node_modules/@clack/prompts/package.json +65 -0
- package/node_modules/create-maizzle/package.json +47 -0
- package/node_modules/create-maizzle/src/index.js +242 -0
- package/node_modules/defu/LICENSE +21 -0
- package/node_modules/defu/README.md +171 -0
- package/node_modules/defu/dist/defu.cjs +77 -0
- package/node_modules/defu/dist/defu.d.cts +31 -0
- package/node_modules/defu/dist/defu.d.mts +29 -0
- package/node_modules/defu/dist/defu.d.ts +31 -0
- package/node_modules/defu/dist/defu.mjs +69 -0
- package/node_modules/defu/lib/defu.cjs +10 -0
- package/node_modules/defu/lib/defu.d.cts +12 -0
- package/node_modules/defu/package.json +48 -0
- package/node_modules/fast-string-truncated-width/dist/index.d.ts +4 -0
- package/node_modules/fast-string-truncated-width/dist/index.js +171 -0
- package/node_modules/fast-string-truncated-width/dist/types.d.ts +22 -0
- package/node_modules/fast-string-truncated-width/dist/types.js +2 -0
- package/node_modules/fast-string-truncated-width/dist/utils.d.ts +4 -0
- package/node_modules/fast-string-truncated-width/dist/utils.js +15 -0
- package/node_modules/fast-string-truncated-width/license +21 -0
- package/node_modules/fast-string-truncated-width/package.json +35 -0
- package/node_modules/fast-string-truncated-width/readme.md +60 -0
- package/node_modules/fast-string-width/dist/index.d.ts +4 -0
- package/node_modules/fast-string-width/dist/index.js +14 -0
- package/node_modules/fast-string-width/license +21 -0
- package/node_modules/fast-string-width/package.json +34 -0
- package/node_modules/fast-string-width/readme.md +45 -0
- package/node_modules/fast-wrap-ansi/LICENSE +23 -0
- package/node_modules/fast-wrap-ansi/README.md +26 -0
- package/node_modules/fast-wrap-ansi/lib/main.d.ts +6 -0
- package/node_modules/fast-wrap-ansi/lib/main.js +216 -0
- package/node_modules/fast-wrap-ansi/lib/main.js.map +1 -0
- package/node_modules/fast-wrap-ansi/package.json +51 -0
- package/node_modules/giget/LICENSE +184 -0
- package/node_modules/giget/README.md +248 -0
- package/node_modules/giget/dist/cli.mjs +112 -0
- package/node_modules/giget/dist/index.d.mts +49 -0
- package/node_modules/giget/dist/index.mjs +22 -0
- package/node_modules/giget/dist/shared/giget.OCaTp9b-.mjs +468 -0
- package/node_modules/giget/package.json +62 -0
- package/node_modules/node-fetch-native/LICENSE +114 -0
- package/node_modules/node-fetch-native/README.md +225 -0
- package/node_modules/node-fetch-native/dist/chunks/multipart-parser.cjs +2 -0
- package/node_modules/node-fetch-native/dist/chunks/multipart-parser.mjs +2 -0
- package/node_modules/node-fetch-native/dist/index.cjs +1 -0
- package/node_modules/node-fetch-native/dist/index.mjs +1 -0
- package/node_modules/node-fetch-native/dist/native.cjs +1 -0
- package/node_modules/node-fetch-native/dist/native.mjs +1 -0
- package/node_modules/node-fetch-native/dist/node.cjs +19 -0
- package/node_modules/node-fetch-native/dist/node.mjs +19 -0
- package/node_modules/node-fetch-native/dist/polyfill.cjs +1 -0
- package/node_modules/node-fetch-native/dist/polyfill.mjs +1 -0
- package/node_modules/node-fetch-native/dist/proxy-stub.cjs +1 -0
- package/node_modules/node-fetch-native/dist/proxy-stub.mjs +1 -0
- package/node_modules/node-fetch-native/dist/proxy.cjs +58 -0
- package/node_modules/node-fetch-native/dist/shared/node-fetch-native.DfbY2q-x.mjs +1 -0
- package/node_modules/node-fetch-native/dist/shared/node-fetch-native.DhEqb06g.cjs +1 -0
- package/node_modules/node-fetch-native/index.d.ts +1 -0
- package/node_modules/node-fetch-native/lib/empty.cjs +0 -0
- package/node_modules/node-fetch-native/lib/empty.mjs +0 -0
- package/node_modules/node-fetch-native/lib/index.cjs +11 -0
- package/node_modules/node-fetch-native/lib/index.d.cts +10 -0
- package/node_modules/node-fetch-native/lib/index.d.mts +10 -0
- package/node_modules/node-fetch-native/lib/index.d.ts +10 -0
- package/node_modules/node-fetch-native/lib/native.cjs +11 -0
- package/node_modules/node-fetch-native/lib/polyfill.d.cts +1 -0
- package/node_modules/node-fetch-native/lib/polyfill.d.mts +1 -0
- package/node_modules/node-fetch-native/lib/polyfill.d.ts +1 -0
- package/node_modules/node-fetch-native/lib/proxy.d.ts +32 -0
- package/node_modules/node-fetch-native/node.d.ts +1 -0
- package/node_modules/node-fetch-native/package.json +138 -0
- package/node_modules/node-fetch-native/polyfill.d.ts +1 -0
- package/node_modules/node-fetch-native/proxy.d.ts +1 -0
- package/node_modules/nypm/LICENSE +21 -0
- package/node_modules/nypm/README.md +152 -0
- package/node_modules/nypm/dist/cli.d.mts +1 -0
- package/node_modules/nypm/dist/cli.mjs +460 -0
- package/node_modules/nypm/dist/index.d.mts +209 -0
- package/node_modules/nypm/dist/index.mjs +423 -0
- package/node_modules/nypm/node_modules/citty/LICENSE +21 -0
- package/node_modules/nypm/node_modules/citty/README.md +231 -0
- package/node_modules/nypm/node_modules/citty/dist/THIRD-PARTY-LICENSES.md +33 -0
- package/node_modules/nypm/node_modules/citty/dist/_chunks/libs/scule.mjs +70 -0
- package/node_modules/nypm/node_modules/citty/dist/index.d.mts +112 -0
- package/node_modules/nypm/node_modules/citty/dist/index.mjs +425 -0
- package/node_modules/nypm/node_modules/citty/package.json +42 -0
- package/node_modules/nypm/package.json +54 -0
- package/node_modules/pathe/LICENSE +70 -0
- package/node_modules/pathe/README.md +73 -0
- package/node_modules/pathe/dist/index.cjs +39 -0
- package/node_modules/pathe/dist/index.d.cts +47 -0
- package/node_modules/pathe/dist/index.d.mts +47 -0
- package/node_modules/pathe/dist/index.d.ts +47 -0
- package/node_modules/pathe/dist/index.mjs +19 -0
- package/node_modules/pathe/dist/shared/pathe.BSlhyZSM.cjs +266 -0
- package/node_modules/pathe/dist/shared/pathe.M-eThtNZ.mjs +249 -0
- package/node_modules/pathe/dist/utils.cjs +82 -0
- package/node_modules/pathe/dist/utils.d.cts +32 -0
- package/node_modules/pathe/dist/utils.d.mts +32 -0
- package/node_modules/pathe/dist/utils.d.ts +32 -0
- package/node_modules/pathe/dist/utils.mjs +77 -0
- package/node_modules/pathe/package.json +61 -0
- package/node_modules/pathe/utils.d.ts +1 -0
- package/node_modules/picocolors/LICENSE +15 -0
- package/node_modules/picocolors/README.md +21 -0
- package/node_modules/picocolors/package.json +25 -0
- package/node_modules/picocolors/picocolors.browser.js +4 -0
- package/node_modules/picocolors/picocolors.d.ts +5 -0
- package/node_modules/picocolors/picocolors.js +75 -0
- package/node_modules/picocolors/types.d.ts +51 -0
- package/node_modules/sisteransi/license +21 -0
- package/node_modules/sisteransi/package.json +34 -0
- package/node_modules/sisteransi/readme.md +113 -0
- package/node_modules/sisteransi/src/index.js +58 -0
- package/node_modules/sisteransi/src/sisteransi.d.ts +35 -0
- package/node_modules/tinyexec/LICENSE +21 -0
- package/node_modules/tinyexec/README.md +269 -0
- package/node_modules/tinyexec/dist/LICENSES.txt +83 -0
- package/node_modules/tinyexec/dist/main.d.mts +71 -0
- package/node_modules/tinyexec/dist/main.mjs +642 -0
- package/node_modules/tinyexec/package.json +62 -0
- package/package.json +74 -73
- package/CHANGELOG.md +0 -770
- package/bin/maizzle +0 -5
- package/src/commands/build.js +0 -348
- package/src/commands/serve.js +0 -3
- package/src/generators/plaintext.js +0 -222
- package/src/generators/render.js +0 -129
- package/src/index.js +0 -49
- package/src/posthtml/defaultComponentsConfig.js +0 -19
- package/src/posthtml/defaultConfig.js +0 -14
- package/src/posthtml/index.js +0 -102
- package/src/posthtml/plugins/combineMediaQueries.js +0 -42
- package/src/posthtml/plugins/envAttributes.js +0 -32
- package/src/posthtml/plugins/envTags.js +0 -33
- package/src/posthtml/plugins/expandLinkTag.js +0 -59
- package/src/posthtml/plugins/postcss/compileCss.js +0 -125
- package/src/posthtml/plugins/removeRawStyleAttributes.js +0 -30
- package/src/server/client.js +0 -182
- package/src/server/index.js +0 -464
- package/src/server/routes/hmr.js +0 -26
- package/src/server/routes/index.js +0 -77
- package/src/server/views/404.html +0 -59
- package/src/server/views/error.html +0 -83
- package/src/server/views/index.html +0 -172
- package/src/server/websockets.js +0 -27
- package/src/transformers/addAttributes.js +0 -29
- package/src/transformers/attributeToStyle.js +0 -90
- package/src/transformers/baseUrl.js +0 -154
- package/src/transformers/core.js +0 -32
- package/src/transformers/filters/defaultFilters.js +0 -146
- package/src/transformers/filters/index.js +0 -18
- package/src/transformers/index.js +0 -259
- package/src/transformers/inline.js +0 -306
- package/src/transformers/markdown.js +0 -26
- package/src/transformers/minify.js +0 -27
- package/src/transformers/posthtmlMso.js +0 -14
- package/src/transformers/prettify.js +0 -29
- package/src/transformers/preventWidows.js +0 -37
- package/src/transformers/purge.js +0 -56
- package/src/transformers/removeAttributes.js +0 -55
- package/src/transformers/replaceStrings.js +0 -37
- package/src/transformers/safeClassNames.js +0 -29
- package/src/transformers/shorthandCss.js +0 -20
- package/src/transformers/sixHex.js +0 -30
- package/src/transformers/template.js +0 -26
- package/src/transformers/urlParameters.js +0 -20
- package/src/transformers/useAttributeSizes.js +0 -63
- package/src/utils/getConfigByFilePath.js +0 -143
- package/src/utils/node.js +0 -68
- package/src/utils/string.js +0 -186
- package/types/build.d.ts +0 -166
- package/types/config.d.ts +0 -638
- package/types/css/combineMediaQueries.d.ts +0 -90
- package/types/css/inline.d.ts +0 -218
- package/types/css/purge.d.ts +0 -125
- package/types/events.d.ts +0 -153
- package/types/index.d.ts +0 -232
- package/types/markdown.d.ts +0 -33
- package/types/minify.d.ts +0 -138
- package/types/plaintext.d.ts +0 -56
- package/types/posthtml.d.ts +0 -162
- package/types/render.d.ts +0 -13
- package/types/urlParameters.d.ts +0 -40
- package/types/widowWords.d.ts +0 -38
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "nypm",
|
|
3
|
+
"version": "0.6.5",
|
|
4
|
+
"description": "Unified Package Manager for Node.js",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"repository": "unjs/nypm",
|
|
7
|
+
"bin": {
|
|
8
|
+
"nypm": "./dist/cli.mjs"
|
|
9
|
+
},
|
|
10
|
+
"files": [
|
|
11
|
+
"dist"
|
|
12
|
+
],
|
|
13
|
+
"type": "module",
|
|
14
|
+
"sideEffects": false,
|
|
15
|
+
"module": "./dist/index.mjs",
|
|
16
|
+
"types": "./dist/index.d.mts",
|
|
17
|
+
"exports": {
|
|
18
|
+
".": "./dist/index.mjs"
|
|
19
|
+
},
|
|
20
|
+
"dependencies": {
|
|
21
|
+
"citty": "^0.2.0",
|
|
22
|
+
"pathe": "^2.0.3",
|
|
23
|
+
"tinyexec": "^1.0.2"
|
|
24
|
+
},
|
|
25
|
+
"devDependencies": {
|
|
26
|
+
"@types/node": "^25.2.1",
|
|
27
|
+
"@typescript/native-preview": "^7.0.0-dev.20260205.1",
|
|
28
|
+
"@vitest/coverage-v8": "^4.0.18",
|
|
29
|
+
"automd": "^0.4.3",
|
|
30
|
+
"changelogen": "^0.6.2",
|
|
31
|
+
"eslint-config-unjs": "^0.6.2",
|
|
32
|
+
"obuild": "^0.4.22",
|
|
33
|
+
"oxfmt": "^0.28.0",
|
|
34
|
+
"oxlint": "^1.43.0",
|
|
35
|
+
"pkg-types": "^2.3.0",
|
|
36
|
+
"std-env": "^3.10.0",
|
|
37
|
+
"typescript": "^5.9.3",
|
|
38
|
+
"ufo": "^1.6.3",
|
|
39
|
+
"vitest": "^4.0.18"
|
|
40
|
+
},
|
|
41
|
+
"engines": {
|
|
42
|
+
"node": ">=18"
|
|
43
|
+
},
|
|
44
|
+
"scripts": {
|
|
45
|
+
"build": "automd && obuild",
|
|
46
|
+
"dev": "vitest dev",
|
|
47
|
+
"lint": "oxlint . && oxfmt --check src test",
|
|
48
|
+
"lint:fix": "oxlint . --fix && oxfmt src test",
|
|
49
|
+
"nypm": "node ./src/cli.ts",
|
|
50
|
+
"release": "pnpm test && pnpm build && changelogen --release --push && pnpm publish",
|
|
51
|
+
"test": "pnpm lint && pnpm test:types && vitest run --coverage",
|
|
52
|
+
"test:types": "tsgo --noEmit"
|
|
53
|
+
}
|
|
54
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) Pooya Parsa <pooya@pi0.io> - Daniel Roe <daniel@roe.dev>
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
Copyright Joyent, Inc. and other Node contributors.
|
|
26
|
+
|
|
27
|
+
Permission is hereby granted, free of charge, to any person obtaining a
|
|
28
|
+
copy of this software and associated documentation files (the
|
|
29
|
+
"Software"), to deal in the Software without restriction, including
|
|
30
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
|
31
|
+
distribute, sublicense, and/or sell copies of the Software, and to permit
|
|
32
|
+
persons to whom the Software is furnished to do so, subject to the
|
|
33
|
+
following conditions:
|
|
34
|
+
|
|
35
|
+
The above copyright notice and this permission notice shall be included
|
|
36
|
+
in all copies or substantial portions of the Software.
|
|
37
|
+
|
|
38
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
|
39
|
+
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
40
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
|
|
41
|
+
NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
|
42
|
+
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
|
43
|
+
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
|
|
44
|
+
USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
45
|
+
|
|
46
|
+
---
|
|
47
|
+
|
|
48
|
+
Bundled zeptomatch (https://github.com/fabiospampinato/zeptomatch)
|
|
49
|
+
|
|
50
|
+
The MIT License (MIT)
|
|
51
|
+
|
|
52
|
+
Copyright (c) 2023-present Fabio Spampinato
|
|
53
|
+
|
|
54
|
+
Permission is hereby granted, free of charge, to any person obtaining a
|
|
55
|
+
copy of this software and associated documentation files (the "Software"),
|
|
56
|
+
to deal in the Software without restriction, including without limitation
|
|
57
|
+
the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
|
58
|
+
and/or sell copies of the Software, and to permit persons to whom the
|
|
59
|
+
Software is furnished to do so, subject to the following conditions:
|
|
60
|
+
|
|
61
|
+
The above copyright notice and this permission notice shall be included in
|
|
62
|
+
all copies or substantial portions of the Software.
|
|
63
|
+
|
|
64
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
65
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
66
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
67
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
68
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
69
|
+
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
|
70
|
+
DEALINGS IN THE SOFTWARE.
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# 🛣️ pathe
|
|
2
|
+
|
|
3
|
+
> Universal filesystem path utils
|
|
4
|
+
|
|
5
|
+
[![version][npm-v-src]][npm-v-href]
|
|
6
|
+
[![downloads][npm-d-src]][npm-d-href]
|
|
7
|
+
[![size][size-src]][size-href]
|
|
8
|
+
|
|
9
|
+
## ❓ Why
|
|
10
|
+
|
|
11
|
+
For [historical reasons](https://docs.microsoft.com/en-us/archive/blogs/larryosterman/why-is-the-dos-path-character), windows followed MS-DOS and used backslash for separating paths rather than slash used for macOS, Linux, and other Posix operating systems. Nowadays, [Windows](https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file?redirectedfrom=MSDN) supports both Slash and Backslash for paths. [Node.js's built-in `path` module](https://nodejs.org/api/path.html) in the default operation of the path module varies based on the operating system on which a Node.js application is running. Specifically, when running on a Windows operating system, the path module will assume that Windows-style paths are being used. **This makes inconsistent code behavior between Windows and POSIX.**
|
|
12
|
+
|
|
13
|
+
Compared to popular [upath](https://github.com/anodynos/upath), pathe provides **identical exports** of Node.js with normalization on **all operations** and is written in modern **ESM/TypeScript** and has **no dependency on Node.js**!
|
|
14
|
+
|
|
15
|
+
This package is a drop-in replacement of the Node.js's [path module](https://nodejs.org/api/path.html) module and ensures paths are normalized with slash `/` and work in environments including Node.js.
|
|
16
|
+
|
|
17
|
+
## 💿 Usage
|
|
18
|
+
|
|
19
|
+
Install using npm or yarn:
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
# npm
|
|
23
|
+
npm i pathe
|
|
24
|
+
|
|
25
|
+
# yarn
|
|
26
|
+
yarn add pathe
|
|
27
|
+
|
|
28
|
+
# pnpm
|
|
29
|
+
pnpm i pathe
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
Import:
|
|
33
|
+
|
|
34
|
+
```js
|
|
35
|
+
// ESM / Typescript
|
|
36
|
+
import { resolve, matchesGlob } from "pathe";
|
|
37
|
+
|
|
38
|
+
// CommonJS
|
|
39
|
+
const { resolve, matchesGlob } = require("pathe");
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Read more about path utils from [Node.js documentation](https://nodejs.org/api/path.html) and rest assured behavior is consistently like POSIX regardless of your input paths format and running platform (the only exception is `delimiter` constant export, it will be set to `;` on windows platform).
|
|
43
|
+
|
|
44
|
+
### Extra utilities
|
|
45
|
+
|
|
46
|
+
Pathe exports some extra utilities that do not exist in standard Node.js [path module](https://nodejs.org/api/path.html).
|
|
47
|
+
In order to use them, you can import from `pathe/utils` subpath:
|
|
48
|
+
|
|
49
|
+
```js
|
|
50
|
+
import {
|
|
51
|
+
filename,
|
|
52
|
+
normalizeAliases,
|
|
53
|
+
resolveAlias,
|
|
54
|
+
reverseResolveAlias,
|
|
55
|
+
} from "pathe/utils";
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
## License
|
|
59
|
+
|
|
60
|
+
Made with 💛 Published under the [MIT](./LICENSE) license.
|
|
61
|
+
|
|
62
|
+
Some code was used from the Node.js project. Glob supported is powered by [zeptomatch](https://github.com/fabiospampinato/zeptomatch).
|
|
63
|
+
|
|
64
|
+
<!-- Refs -->
|
|
65
|
+
|
|
66
|
+
[npm-v-src]: https://img.shields.io/npm/v/pathe?style=flat-square
|
|
67
|
+
[npm-v-href]: https://npmjs.com/package/pathe
|
|
68
|
+
[npm-d-src]: https://img.shields.io/npm/dm/pathe?style=flat-square
|
|
69
|
+
[npm-d-href]: https://npmjs.com/package/pathe
|
|
70
|
+
[github-actions-src]: https://img.shields.io/github/workflow/status/unjs/pathe/ci/main?style=flat-square
|
|
71
|
+
[github-actions-href]: https://github.com/unjs/pathe/actions?query=workflow%3Aci
|
|
72
|
+
[size-src]: https://packagephobia.now.sh/badge?p=pathe
|
|
73
|
+
[size-href]: https://packagephobia.now.sh/result?p=pathe
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const _path = require('./shared/pathe.BSlhyZSM.cjs');
|
|
6
|
+
|
|
7
|
+
const delimiter = /* @__PURE__ */ (() => globalThis.process?.platform === "win32" ? ";" : ":")();
|
|
8
|
+
const _platforms = { posix: void 0, win32: void 0 };
|
|
9
|
+
const mix = (del = delimiter) => {
|
|
10
|
+
return new Proxy(_path._path, {
|
|
11
|
+
get(_, prop) {
|
|
12
|
+
if (prop === "delimiter") return del;
|
|
13
|
+
if (prop === "posix") return posix;
|
|
14
|
+
if (prop === "win32") return win32;
|
|
15
|
+
return _platforms[prop] || _path._path[prop];
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
const posix = /* @__PURE__ */ mix(":");
|
|
20
|
+
const win32 = /* @__PURE__ */ mix(";");
|
|
21
|
+
|
|
22
|
+
exports.basename = _path.basename;
|
|
23
|
+
exports.dirname = _path.dirname;
|
|
24
|
+
exports.extname = _path.extname;
|
|
25
|
+
exports.format = _path.format;
|
|
26
|
+
exports.isAbsolute = _path.isAbsolute;
|
|
27
|
+
exports.join = _path.join;
|
|
28
|
+
exports.matchesGlob = _path.matchesGlob;
|
|
29
|
+
exports.normalize = _path.normalize;
|
|
30
|
+
exports.normalizeString = _path.normalizeString;
|
|
31
|
+
exports.parse = _path.parse;
|
|
32
|
+
exports.relative = _path.relative;
|
|
33
|
+
exports.resolve = _path.resolve;
|
|
34
|
+
exports.sep = _path.sep;
|
|
35
|
+
exports.toNamespacedPath = _path.toNamespacedPath;
|
|
36
|
+
exports.default = posix;
|
|
37
|
+
exports.delimiter = delimiter;
|
|
38
|
+
exports.posix = posix;
|
|
39
|
+
exports.win32 = win32;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import * as path from 'node:path';
|
|
2
|
+
import path__default from 'node:path';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Constant for path separator.
|
|
6
|
+
*
|
|
7
|
+
* Always equals to `"/"`.
|
|
8
|
+
*/
|
|
9
|
+
declare const sep = "/";
|
|
10
|
+
declare const normalize: typeof path__default.normalize;
|
|
11
|
+
declare const join: typeof path__default.join;
|
|
12
|
+
declare const resolve: typeof path__default.resolve;
|
|
13
|
+
/**
|
|
14
|
+
* Resolves a string path, resolving '.' and '.' segments and allowing paths above the root.
|
|
15
|
+
*
|
|
16
|
+
* @param path - The path to normalise.
|
|
17
|
+
* @param allowAboveRoot - Whether to allow the resulting path to be above the root directory.
|
|
18
|
+
* @returns the normalised path string.
|
|
19
|
+
*/
|
|
20
|
+
declare function normalizeString(path: string, allowAboveRoot: boolean): string;
|
|
21
|
+
declare const isAbsolute: typeof path__default.isAbsolute;
|
|
22
|
+
declare const toNamespacedPath: typeof path__default.toNamespacedPath;
|
|
23
|
+
declare const extname: typeof path__default.extname;
|
|
24
|
+
declare const relative: typeof path__default.relative;
|
|
25
|
+
declare const dirname: typeof path__default.dirname;
|
|
26
|
+
declare const format: typeof path__default.format;
|
|
27
|
+
declare const basename: typeof path__default.basename;
|
|
28
|
+
declare const parse: typeof path__default.parse;
|
|
29
|
+
/**
|
|
30
|
+
* The `path.matchesGlob()` method determines if `path` matches the `pattern`.
|
|
31
|
+
* @param path The path to glob-match against.
|
|
32
|
+
* @param pattern The glob to check the path against.
|
|
33
|
+
*/
|
|
34
|
+
declare const matchesGlob: (path: string, pattern: string | string[]) => boolean;
|
|
35
|
+
|
|
36
|
+
type NodePath = typeof path;
|
|
37
|
+
/**
|
|
38
|
+
* The platform-specific file delimiter.
|
|
39
|
+
*
|
|
40
|
+
* Equals to `";"` in windows and `":"` in all other platforms.
|
|
41
|
+
*/
|
|
42
|
+
declare const delimiter: ";" | ":";
|
|
43
|
+
declare const posix: NodePath["posix"];
|
|
44
|
+
declare const win32: NodePath["win32"];
|
|
45
|
+
declare const _default: NodePath;
|
|
46
|
+
|
|
47
|
+
export { basename, _default as default, delimiter, dirname, extname, format, isAbsolute, join, matchesGlob, normalize, normalizeString, parse, posix, relative, resolve, sep, toNamespacedPath, win32 };
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import * as path from 'node:path';
|
|
2
|
+
import path__default from 'node:path';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Constant for path separator.
|
|
6
|
+
*
|
|
7
|
+
* Always equals to `"/"`.
|
|
8
|
+
*/
|
|
9
|
+
declare const sep = "/";
|
|
10
|
+
declare const normalize: typeof path__default.normalize;
|
|
11
|
+
declare const join: typeof path__default.join;
|
|
12
|
+
declare const resolve: typeof path__default.resolve;
|
|
13
|
+
/**
|
|
14
|
+
* Resolves a string path, resolving '.' and '.' segments and allowing paths above the root.
|
|
15
|
+
*
|
|
16
|
+
* @param path - The path to normalise.
|
|
17
|
+
* @param allowAboveRoot - Whether to allow the resulting path to be above the root directory.
|
|
18
|
+
* @returns the normalised path string.
|
|
19
|
+
*/
|
|
20
|
+
declare function normalizeString(path: string, allowAboveRoot: boolean): string;
|
|
21
|
+
declare const isAbsolute: typeof path__default.isAbsolute;
|
|
22
|
+
declare const toNamespacedPath: typeof path__default.toNamespacedPath;
|
|
23
|
+
declare const extname: typeof path__default.extname;
|
|
24
|
+
declare const relative: typeof path__default.relative;
|
|
25
|
+
declare const dirname: typeof path__default.dirname;
|
|
26
|
+
declare const format: typeof path__default.format;
|
|
27
|
+
declare const basename: typeof path__default.basename;
|
|
28
|
+
declare const parse: typeof path__default.parse;
|
|
29
|
+
/**
|
|
30
|
+
* The `path.matchesGlob()` method determines if `path` matches the `pattern`.
|
|
31
|
+
* @param path The path to glob-match against.
|
|
32
|
+
* @param pattern The glob to check the path against.
|
|
33
|
+
*/
|
|
34
|
+
declare const matchesGlob: (path: string, pattern: string | string[]) => boolean;
|
|
35
|
+
|
|
36
|
+
type NodePath = typeof path;
|
|
37
|
+
/**
|
|
38
|
+
* The platform-specific file delimiter.
|
|
39
|
+
*
|
|
40
|
+
* Equals to `";"` in windows and `":"` in all other platforms.
|
|
41
|
+
*/
|
|
42
|
+
declare const delimiter: ";" | ":";
|
|
43
|
+
declare const posix: NodePath["posix"];
|
|
44
|
+
declare const win32: NodePath["win32"];
|
|
45
|
+
declare const _default: NodePath;
|
|
46
|
+
|
|
47
|
+
export { basename, _default as default, delimiter, dirname, extname, format, isAbsolute, join, matchesGlob, normalize, normalizeString, parse, posix, relative, resolve, sep, toNamespacedPath, win32 };
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import * as path from 'node:path';
|
|
2
|
+
import path__default from 'node:path';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Constant for path separator.
|
|
6
|
+
*
|
|
7
|
+
* Always equals to `"/"`.
|
|
8
|
+
*/
|
|
9
|
+
declare const sep = "/";
|
|
10
|
+
declare const normalize: typeof path__default.normalize;
|
|
11
|
+
declare const join: typeof path__default.join;
|
|
12
|
+
declare const resolve: typeof path__default.resolve;
|
|
13
|
+
/**
|
|
14
|
+
* Resolves a string path, resolving '.' and '.' segments and allowing paths above the root.
|
|
15
|
+
*
|
|
16
|
+
* @param path - The path to normalise.
|
|
17
|
+
* @param allowAboveRoot - Whether to allow the resulting path to be above the root directory.
|
|
18
|
+
* @returns the normalised path string.
|
|
19
|
+
*/
|
|
20
|
+
declare function normalizeString(path: string, allowAboveRoot: boolean): string;
|
|
21
|
+
declare const isAbsolute: typeof path__default.isAbsolute;
|
|
22
|
+
declare const toNamespacedPath: typeof path__default.toNamespacedPath;
|
|
23
|
+
declare const extname: typeof path__default.extname;
|
|
24
|
+
declare const relative: typeof path__default.relative;
|
|
25
|
+
declare const dirname: typeof path__default.dirname;
|
|
26
|
+
declare const format: typeof path__default.format;
|
|
27
|
+
declare const basename: typeof path__default.basename;
|
|
28
|
+
declare const parse: typeof path__default.parse;
|
|
29
|
+
/**
|
|
30
|
+
* The `path.matchesGlob()` method determines if `path` matches the `pattern`.
|
|
31
|
+
* @param path The path to glob-match against.
|
|
32
|
+
* @param pattern The glob to check the path against.
|
|
33
|
+
*/
|
|
34
|
+
declare const matchesGlob: (path: string, pattern: string | string[]) => boolean;
|
|
35
|
+
|
|
36
|
+
type NodePath = typeof path;
|
|
37
|
+
/**
|
|
38
|
+
* The platform-specific file delimiter.
|
|
39
|
+
*
|
|
40
|
+
* Equals to `";"` in windows and `":"` in all other platforms.
|
|
41
|
+
*/
|
|
42
|
+
declare const delimiter: ";" | ":";
|
|
43
|
+
declare const posix: NodePath["posix"];
|
|
44
|
+
declare const win32: NodePath["win32"];
|
|
45
|
+
declare const _default: NodePath;
|
|
46
|
+
|
|
47
|
+
export { basename, _default as default, delimiter, dirname, extname, format, isAbsolute, join, matchesGlob, normalize, normalizeString, parse, posix, relative, resolve, sep, toNamespacedPath, win32 };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { _ as _path } from './shared/pathe.M-eThtNZ.mjs';
|
|
2
|
+
export { c as basename, d as dirname, e as extname, f as format, i as isAbsolute, j as join, m as matchesGlob, n as normalize, a as normalizeString, p as parse, b as relative, r as resolve, s as sep, t as toNamespacedPath } from './shared/pathe.M-eThtNZ.mjs';
|
|
3
|
+
|
|
4
|
+
const delimiter = /* @__PURE__ */ (() => globalThis.process?.platform === "win32" ? ";" : ":")();
|
|
5
|
+
const _platforms = { posix: void 0, win32: void 0 };
|
|
6
|
+
const mix = (del = delimiter) => {
|
|
7
|
+
return new Proxy(_path, {
|
|
8
|
+
get(_, prop) {
|
|
9
|
+
if (prop === "delimiter") return del;
|
|
10
|
+
if (prop === "posix") return posix;
|
|
11
|
+
if (prop === "win32") return win32;
|
|
12
|
+
return _platforms[prop] || _path[prop];
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
};
|
|
16
|
+
const posix = /* @__PURE__ */ mix(":");
|
|
17
|
+
const win32 = /* @__PURE__ */ mix(";");
|
|
18
|
+
|
|
19
|
+
export { posix as default, delimiter, posix, win32 };
|
|
@@ -0,0 +1,266 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
let _lazyMatch = () => { var __lib__=(()=>{var m=Object.defineProperty,V=Object.getOwnPropertyDescriptor,G=Object.getOwnPropertyNames,T=Object.prototype.hasOwnProperty,q=(r,e)=>{for(var n in e)m(r,n,{get:e[n],enumerable:true});},H=(r,e,n,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let t of G(e))!T.call(r,t)&&t!==n&&m(r,t,{get:()=>e[t],enumerable:!(a=V(e,t))||a.enumerable});return r},J=r=>H(m({},"__esModule",{value:true}),r),w={};q(w,{default:()=>re});var A=r=>Array.isArray(r),d=r=>typeof r=="function",Q=r=>r.length===0,W=r=>typeof r=="number",K=r=>typeof r=="object"&&r!==null,X=r=>r instanceof RegExp,b=r=>typeof r=="string",h=r=>r===void 0,Y=r=>{const e=new Map;return n=>{const a=e.get(n);if(a)return a;const t=r(n);return e.set(n,t),t}},rr=(r,e,n={})=>{const a={cache:{},input:r,index:0,indexMax:0,options:n,output:[]};if(v(e)(a)&&a.index===r.length)return a.output;throw new Error(`Failed to parse at index ${a.indexMax}`)},i=(r,e)=>A(r)?er(r,e):b(r)?ar(r,e):nr(r,e),er=(r,e)=>{const n={};for(const a of r){if(a.length!==1)throw new Error(`Invalid character: "${a}"`);const t=a.charCodeAt(0);n[t]=true;}return a=>{const t=a.index,o=a.input;for(;a.index<o.length&&o.charCodeAt(a.index)in n;)a.index+=1;const u=a.index;if(u>t){if(!h(e)&&!a.options.silent){const s=a.input.slice(t,u),c=d(e)?e(s,o,String(t)):e;h(c)||a.output.push(c);}a.indexMax=Math.max(a.indexMax,a.index);}return true}},nr=(r,e)=>{const n=r.source,a=r.flags.replace(/y|$/,"y"),t=new RegExp(n,a);return g(o=>{t.lastIndex=o.index;const u=t.exec(o.input);if(u){if(!h(e)&&!o.options.silent){const s=d(e)?e(...u,o.input,String(o.index)):e;h(s)||o.output.push(s);}return o.index+=u[0].length,o.indexMax=Math.max(o.indexMax,o.index),true}else return false})},ar=(r,e)=>n=>{if(n.input.startsWith(r,n.index)){if(!h(e)&&!n.options.silent){const t=d(e)?e(r,n.input,String(n.index)):e;h(t)||n.output.push(t);}return n.index+=r.length,n.indexMax=Math.max(n.indexMax,n.index),true}else return false},C=(r,e,n,a)=>{const t=v(r);return g(_(M(o=>{let u=0;for(;u<n;){const s=o.index;if(!t(o)||(u+=1,o.index===s))break}return u>=e})))},tr=(r,e)=>C(r,0,1),f=(r,e)=>C(r,0,1/0),x=(r,e)=>{const n=r.map(v);return g(_(M(a=>{for(let t=0,o=n.length;t<o;t++)if(!n[t](a))return false;return true})))},l=(r,e)=>{const n=r.map(v);return g(_(a=>{for(let t=0,o=n.length;t<o;t++)if(n[t](a))return true;return false}))},M=(r,e=false)=>{const n=v(r);return a=>{const t=a.index,o=a.output.length,u=n(a);return (!u||e)&&(a.index=t,a.output.length!==o&&(a.output.length=o)),u}},_=(r,e)=>{const n=v(r);return n},g=(()=>{let r=0;return e=>{const n=v(e),a=r+=1;return t=>{var o;if(t.options.memoization===false)return n(t);const u=t.index,s=(o=t.cache)[a]||(o[a]=new Map),c=s.get(u);if(c===false)return false;if(W(c))return t.index=c,true;if(c)return t.index=c.index,c.output?.length&&t.output.push(...c.output),true;{const Z=t.output.length;if(n(t)){const D=t.index,U=t.output.length;if(U>Z){const ee=t.output.slice(Z,U);s.set(u,{index:D,output:ee});}else s.set(u,D);return true}else return s.set(u,false),false}}}})(),E=r=>{let e;return n=>(e||(e=v(r())),e(n))},v=Y(r=>{if(d(r))return Q(r)?E(r):r;if(b(r)||X(r))return i(r);if(A(r))return x(r);if(K(r))return l(Object.values(r));throw new Error("Invalid rule")}),P="abcdefghijklmnopqrstuvwxyz",ir=r=>{let e="";for(;r>0;){const n=(r-1)%26;e=P[n]+e,r=Math.floor((r-1)/26);}return e},O=r=>{let e=0;for(let n=0,a=r.length;n<a;n++)e=e*26+P.indexOf(r[n])+1;return e},S=(r,e)=>{if(e<r)return S(e,r);const n=[];for(;r<=e;)n.push(r++);return n},or=(r,e,n)=>S(r,e).map(a=>String(a).padStart(n,"0")),R=(r,e)=>S(O(r),O(e)).map(ir),p=r=>r,z=r=>ur(e=>rr(e,r,{memoization:false}).join("")),ur=r=>{const e={};return n=>e[n]??(e[n]=r(n))},sr=i(/^\*\*\/\*$/,".*"),cr=i(/^\*\*\/(\*)?([ a-zA-Z0-9._-]+)$/,(r,e,n)=>`.*${e?"":"(?:^|/)"}${n.replaceAll(".","\\.")}`),lr=i(/^\*\*\/(\*)?([ a-zA-Z0-9._-]*)\{([ a-zA-Z0-9._-]+(?:,[ a-zA-Z0-9._-]+)*)\}$/,(r,e,n,a)=>`.*${e?"":"(?:^|/)"}${n.replaceAll(".","\\.")}(?:${a.replaceAll(",","|").replaceAll(".","\\.")})`),y=i(/\\./,p),pr=i(/[$.*+?^(){}[\]\|]/,r=>`\\${r}`),vr=i(/./,p),hr=i(/^(?:!!)*!(.*)$/,(r,e)=>`(?!^${L(e)}$).*?`),dr=i(/^(!!)+/,""),fr=l([hr,dr]),xr=i(/\/(\*\*\/)+/,"(?:/.+/|/)"),gr=i(/^(\*\*\/)+/,"(?:^|.*/)"),mr=i(/\/(\*\*)$/,"(?:/.*|$)"),_r=i(/\*\*/,".*"),j=l([xr,gr,mr,_r]),Sr=i(/\*\/(?!\*\*\/)/,"[^/]*/"),yr=i(/\*/,"[^/]*"),N=l([Sr,yr]),k=i("?","[^/]"),$r=i("[",p),wr=i("]",p),Ar=i(/[!^]/,"^/"),br=i(/[a-z]-[a-z]|[0-9]-[0-9]/i,p),Cr=i(/[$.*+?^(){}[\|]/,r=>`\\${r}`),Mr=i(/[^\]]/,p),Er=l([y,Cr,br,Mr]),B=x([$r,tr(Ar),f(Er),wr]),Pr=i("{","(?:"),Or=i("}",")"),Rr=i(/(\d+)\.\.(\d+)/,(r,e,n)=>or(+e,+n,Math.min(e.length,n.length)).join("|")),zr=i(/([a-z]+)\.\.([a-z]+)/,(r,e,n)=>R(e,n).join("|")),jr=i(/([A-Z]+)\.\.([A-Z]+)/,(r,e,n)=>R(e.toLowerCase(),n.toLowerCase()).join("|").toUpperCase()),Nr=l([Rr,zr,jr]),I=x([Pr,Nr,Or]),kr=i("{","(?:"),Br=i("}",")"),Ir=i(",","|"),Fr=i(/[$.*+?^(){[\]\|]/,r=>`\\${r}`),Lr=i(/[^}]/,p),Zr=E(()=>F),Dr=l([j,N,k,B,I,Zr,y,Fr,Ir,Lr]),F=x([kr,f(Dr),Br]),Ur=f(l([sr,cr,lr,fr,j,N,k,B,I,F,y,pr,vr])),Vr=Ur,Gr=z(Vr),L=Gr,Tr=i(/\\./,p),qr=i(/./,p),Hr=i(/\*\*\*+/,"*"),Jr=i(/([^/{[(!])\*\*/,(r,e)=>`${e}*`),Qr=i(/(^|.)\*\*(?=[^*/)\]}])/,(r,e)=>`${e}*`),Wr=f(l([Tr,Hr,Jr,Qr,qr])),Kr=Wr,Xr=z(Kr),Yr=Xr,$=(r,e)=>{const n=Array.isArray(r)?r:[r];if(!n.length)return false;const a=n.map($.compile),t=n.every(s=>/(\/(?:\*\*)?|\[\/\])$/.test(s)),o=e.replace(/[\\\/]+/g,"/").replace(/\/$/,t?"/":"");return a.some(s=>s.test(o))};$.compile=r=>new RegExp(`^${L(Yr(r))}$`,"s");var re=$;return J(w)})();
|
|
4
|
+
return __lib__.default || __lib__; };
|
|
5
|
+
let _match;
|
|
6
|
+
const zeptomatch = (path, pattern) => {
|
|
7
|
+
if (!_match) {
|
|
8
|
+
_match = _lazyMatch();
|
|
9
|
+
_lazyMatch = null;
|
|
10
|
+
}
|
|
11
|
+
return _match(path, pattern);
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
const _DRIVE_LETTER_START_RE = /^[A-Za-z]:\//;
|
|
15
|
+
function normalizeWindowsPath(input = "") {
|
|
16
|
+
if (!input) {
|
|
17
|
+
return input;
|
|
18
|
+
}
|
|
19
|
+
return input.replace(/\\/g, "/").replace(_DRIVE_LETTER_START_RE, (r) => r.toUpperCase());
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const _UNC_REGEX = /^[/\\]{2}/;
|
|
23
|
+
const _IS_ABSOLUTE_RE = /^[/\\](?![/\\])|^[/\\]{2}(?!\.)|^[A-Za-z]:[/\\]/;
|
|
24
|
+
const _DRIVE_LETTER_RE = /^[A-Za-z]:$/;
|
|
25
|
+
const _ROOT_FOLDER_RE = /^\/([A-Za-z]:)?$/;
|
|
26
|
+
const _EXTNAME_RE = /.(\.[^./]+|\.)$/;
|
|
27
|
+
const _PATH_ROOT_RE = /^[/\\]|^[a-zA-Z]:[/\\]/;
|
|
28
|
+
const sep = "/";
|
|
29
|
+
const normalize = function(path) {
|
|
30
|
+
if (path.length === 0) {
|
|
31
|
+
return ".";
|
|
32
|
+
}
|
|
33
|
+
path = normalizeWindowsPath(path);
|
|
34
|
+
const isUNCPath = path.match(_UNC_REGEX);
|
|
35
|
+
const isPathAbsolute = isAbsolute(path);
|
|
36
|
+
const trailingSeparator = path[path.length - 1] === "/";
|
|
37
|
+
path = normalizeString(path, !isPathAbsolute);
|
|
38
|
+
if (path.length === 0) {
|
|
39
|
+
if (isPathAbsolute) {
|
|
40
|
+
return "/";
|
|
41
|
+
}
|
|
42
|
+
return trailingSeparator ? "./" : ".";
|
|
43
|
+
}
|
|
44
|
+
if (trailingSeparator) {
|
|
45
|
+
path += "/";
|
|
46
|
+
}
|
|
47
|
+
if (_DRIVE_LETTER_RE.test(path)) {
|
|
48
|
+
path += "/";
|
|
49
|
+
}
|
|
50
|
+
if (isUNCPath) {
|
|
51
|
+
if (!isPathAbsolute) {
|
|
52
|
+
return `//./${path}`;
|
|
53
|
+
}
|
|
54
|
+
return `//${path}`;
|
|
55
|
+
}
|
|
56
|
+
return isPathAbsolute && !isAbsolute(path) ? `/${path}` : path;
|
|
57
|
+
};
|
|
58
|
+
const join = function(...segments) {
|
|
59
|
+
let path = "";
|
|
60
|
+
for (const seg of segments) {
|
|
61
|
+
if (!seg) {
|
|
62
|
+
continue;
|
|
63
|
+
}
|
|
64
|
+
if (path.length > 0) {
|
|
65
|
+
const pathTrailing = path[path.length - 1] === "/";
|
|
66
|
+
const segLeading = seg[0] === "/";
|
|
67
|
+
const both = pathTrailing && segLeading;
|
|
68
|
+
if (both) {
|
|
69
|
+
path += seg.slice(1);
|
|
70
|
+
} else {
|
|
71
|
+
path += pathTrailing || segLeading ? seg : `/${seg}`;
|
|
72
|
+
}
|
|
73
|
+
} else {
|
|
74
|
+
path += seg;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
return normalize(path);
|
|
78
|
+
};
|
|
79
|
+
function cwd() {
|
|
80
|
+
if (typeof process !== "undefined" && typeof process.cwd === "function") {
|
|
81
|
+
return process.cwd().replace(/\\/g, "/");
|
|
82
|
+
}
|
|
83
|
+
return "/";
|
|
84
|
+
}
|
|
85
|
+
const resolve = function(...arguments_) {
|
|
86
|
+
arguments_ = arguments_.map((argument) => normalizeWindowsPath(argument));
|
|
87
|
+
let resolvedPath = "";
|
|
88
|
+
let resolvedAbsolute = false;
|
|
89
|
+
for (let index = arguments_.length - 1; index >= -1 && !resolvedAbsolute; index--) {
|
|
90
|
+
const path = index >= 0 ? arguments_[index] : cwd();
|
|
91
|
+
if (!path || path.length === 0) {
|
|
92
|
+
continue;
|
|
93
|
+
}
|
|
94
|
+
resolvedPath = `${path}/${resolvedPath}`;
|
|
95
|
+
resolvedAbsolute = isAbsolute(path);
|
|
96
|
+
}
|
|
97
|
+
resolvedPath = normalizeString(resolvedPath, !resolvedAbsolute);
|
|
98
|
+
if (resolvedAbsolute && !isAbsolute(resolvedPath)) {
|
|
99
|
+
return `/${resolvedPath}`;
|
|
100
|
+
}
|
|
101
|
+
return resolvedPath.length > 0 ? resolvedPath : ".";
|
|
102
|
+
};
|
|
103
|
+
function normalizeString(path, allowAboveRoot) {
|
|
104
|
+
let res = "";
|
|
105
|
+
let lastSegmentLength = 0;
|
|
106
|
+
let lastSlash = -1;
|
|
107
|
+
let dots = 0;
|
|
108
|
+
let char = null;
|
|
109
|
+
for (let index = 0; index <= path.length; ++index) {
|
|
110
|
+
if (index < path.length) {
|
|
111
|
+
char = path[index];
|
|
112
|
+
} else if (char === "/") {
|
|
113
|
+
break;
|
|
114
|
+
} else {
|
|
115
|
+
char = "/";
|
|
116
|
+
}
|
|
117
|
+
if (char === "/") {
|
|
118
|
+
if (lastSlash === index - 1 || dots === 1) ; else if (dots === 2) {
|
|
119
|
+
if (res.length < 2 || lastSegmentLength !== 2 || res[res.length - 1] !== "." || res[res.length - 2] !== ".") {
|
|
120
|
+
if (res.length > 2) {
|
|
121
|
+
const lastSlashIndex = res.lastIndexOf("/");
|
|
122
|
+
if (lastSlashIndex === -1) {
|
|
123
|
+
res = "";
|
|
124
|
+
lastSegmentLength = 0;
|
|
125
|
+
} else {
|
|
126
|
+
res = res.slice(0, lastSlashIndex);
|
|
127
|
+
lastSegmentLength = res.length - 1 - res.lastIndexOf("/");
|
|
128
|
+
}
|
|
129
|
+
lastSlash = index;
|
|
130
|
+
dots = 0;
|
|
131
|
+
continue;
|
|
132
|
+
} else if (res.length > 0) {
|
|
133
|
+
res = "";
|
|
134
|
+
lastSegmentLength = 0;
|
|
135
|
+
lastSlash = index;
|
|
136
|
+
dots = 0;
|
|
137
|
+
continue;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
if (allowAboveRoot) {
|
|
141
|
+
res += res.length > 0 ? "/.." : "..";
|
|
142
|
+
lastSegmentLength = 2;
|
|
143
|
+
}
|
|
144
|
+
} else {
|
|
145
|
+
if (res.length > 0) {
|
|
146
|
+
res += `/${path.slice(lastSlash + 1, index)}`;
|
|
147
|
+
} else {
|
|
148
|
+
res = path.slice(lastSlash + 1, index);
|
|
149
|
+
}
|
|
150
|
+
lastSegmentLength = index - lastSlash - 1;
|
|
151
|
+
}
|
|
152
|
+
lastSlash = index;
|
|
153
|
+
dots = 0;
|
|
154
|
+
} else if (char === "." && dots !== -1) {
|
|
155
|
+
++dots;
|
|
156
|
+
} else {
|
|
157
|
+
dots = -1;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
return res;
|
|
161
|
+
}
|
|
162
|
+
const isAbsolute = function(p) {
|
|
163
|
+
return _IS_ABSOLUTE_RE.test(p);
|
|
164
|
+
};
|
|
165
|
+
const toNamespacedPath = function(p) {
|
|
166
|
+
return normalizeWindowsPath(p);
|
|
167
|
+
};
|
|
168
|
+
const extname = function(p) {
|
|
169
|
+
if (p === "..") return "";
|
|
170
|
+
const match = _EXTNAME_RE.exec(normalizeWindowsPath(p));
|
|
171
|
+
return match && match[1] || "";
|
|
172
|
+
};
|
|
173
|
+
const relative = function(from, to) {
|
|
174
|
+
const _from = resolve(from).replace(_ROOT_FOLDER_RE, "$1").split("/");
|
|
175
|
+
const _to = resolve(to).replace(_ROOT_FOLDER_RE, "$1").split("/");
|
|
176
|
+
if (_to[0][1] === ":" && _from[0][1] === ":" && _from[0] !== _to[0]) {
|
|
177
|
+
return _to.join("/");
|
|
178
|
+
}
|
|
179
|
+
const _fromCopy = [..._from];
|
|
180
|
+
for (const segment of _fromCopy) {
|
|
181
|
+
if (_to[0] !== segment) {
|
|
182
|
+
break;
|
|
183
|
+
}
|
|
184
|
+
_from.shift();
|
|
185
|
+
_to.shift();
|
|
186
|
+
}
|
|
187
|
+
return [..._from.map(() => ".."), ..._to].join("/");
|
|
188
|
+
};
|
|
189
|
+
const dirname = function(p) {
|
|
190
|
+
const segments = normalizeWindowsPath(p).replace(/\/$/, "").split("/").slice(0, -1);
|
|
191
|
+
if (segments.length === 1 && _DRIVE_LETTER_RE.test(segments[0])) {
|
|
192
|
+
segments[0] += "/";
|
|
193
|
+
}
|
|
194
|
+
return segments.join("/") || (isAbsolute(p) ? "/" : ".");
|
|
195
|
+
};
|
|
196
|
+
const format = function(p) {
|
|
197
|
+
const ext = p.ext ? p.ext.startsWith(".") ? p.ext : `.${p.ext}` : "";
|
|
198
|
+
const segments = [p.root, p.dir, p.base ?? (p.name ?? "") + ext].filter(
|
|
199
|
+
Boolean
|
|
200
|
+
);
|
|
201
|
+
return normalizeWindowsPath(
|
|
202
|
+
p.root ? resolve(...segments) : segments.join("/")
|
|
203
|
+
);
|
|
204
|
+
};
|
|
205
|
+
const basename = function(p, extension) {
|
|
206
|
+
const segments = normalizeWindowsPath(p).split("/");
|
|
207
|
+
let lastSegment = "";
|
|
208
|
+
for (let i = segments.length - 1; i >= 0; i--) {
|
|
209
|
+
const val = segments[i];
|
|
210
|
+
if (val) {
|
|
211
|
+
lastSegment = val;
|
|
212
|
+
break;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
return extension && lastSegment.endsWith(extension) ? lastSegment.slice(0, -extension.length) : lastSegment;
|
|
216
|
+
};
|
|
217
|
+
const parse = function(p) {
|
|
218
|
+
const root = _PATH_ROOT_RE.exec(p)?.[0]?.replace(/\\/g, "/") || "";
|
|
219
|
+
const base = basename(p);
|
|
220
|
+
const extension = extname(base);
|
|
221
|
+
return {
|
|
222
|
+
root,
|
|
223
|
+
dir: dirname(p),
|
|
224
|
+
base,
|
|
225
|
+
ext: extension,
|
|
226
|
+
name: base.slice(0, base.length - extension.length)
|
|
227
|
+
};
|
|
228
|
+
};
|
|
229
|
+
const matchesGlob = (path, pattern) => {
|
|
230
|
+
return zeptomatch(pattern, normalize(path));
|
|
231
|
+
};
|
|
232
|
+
|
|
233
|
+
const _path = {
|
|
234
|
+
__proto__: null,
|
|
235
|
+
basename: basename,
|
|
236
|
+
dirname: dirname,
|
|
237
|
+
extname: extname,
|
|
238
|
+
format: format,
|
|
239
|
+
isAbsolute: isAbsolute,
|
|
240
|
+
join: join,
|
|
241
|
+
matchesGlob: matchesGlob,
|
|
242
|
+
normalize: normalize,
|
|
243
|
+
normalizeString: normalizeString,
|
|
244
|
+
parse: parse,
|
|
245
|
+
relative: relative,
|
|
246
|
+
resolve: resolve,
|
|
247
|
+
sep: sep,
|
|
248
|
+
toNamespacedPath: toNamespacedPath
|
|
249
|
+
};
|
|
250
|
+
|
|
251
|
+
exports._path = _path;
|
|
252
|
+
exports.basename = basename;
|
|
253
|
+
exports.dirname = dirname;
|
|
254
|
+
exports.extname = extname;
|
|
255
|
+
exports.format = format;
|
|
256
|
+
exports.isAbsolute = isAbsolute;
|
|
257
|
+
exports.join = join;
|
|
258
|
+
exports.matchesGlob = matchesGlob;
|
|
259
|
+
exports.normalize = normalize;
|
|
260
|
+
exports.normalizeString = normalizeString;
|
|
261
|
+
exports.normalizeWindowsPath = normalizeWindowsPath;
|
|
262
|
+
exports.parse = parse;
|
|
263
|
+
exports.relative = relative;
|
|
264
|
+
exports.resolve = resolve;
|
|
265
|
+
exports.sep = sep;
|
|
266
|
+
exports.toNamespacedPath = toNamespacedPath;
|