@crustjs/style 0.0.4 → 0.0.6
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/README.md +2 -3
- package/dist/index.d.ts +1 -20
- package/dist/index.js +9 -9
- package/package.json +4 -3
package/README.md
CHANGED
|
@@ -163,7 +163,6 @@ ANSI-aware text measurement and layout:
|
|
|
163
163
|
|
|
164
164
|
```ts
|
|
165
165
|
import {
|
|
166
|
-
stripAnsi,
|
|
167
166
|
visibleWidth,
|
|
168
167
|
wrapText,
|
|
169
168
|
padStart,
|
|
@@ -171,8 +170,8 @@ import {
|
|
|
171
170
|
center,
|
|
172
171
|
} from "@crustjs/style";
|
|
173
172
|
|
|
174
|
-
// Strip ANSI escape sequences
|
|
175
|
-
|
|
173
|
+
// Strip ANSI escape sequences (Bun built-in)
|
|
174
|
+
Bun.stripANSI("\x1b[1mhello\x1b[22m"); // "hello"
|
|
176
175
|
|
|
177
176
|
// Measure visible width (ignores ANSI codes, counts CJK as 2)
|
|
178
177
|
visibleWidth("\x1b[31mhello\x1b[39m"); // 5
|
package/dist/index.d.ts
CHANGED
|
@@ -871,25 +871,6 @@ declare function padEnd(text: string, width: number, fillChar?: string): string;
|
|
|
871
871
|
*/
|
|
872
872
|
declare function center(text: string, width: number, fillChar?: string): string;
|
|
873
873
|
/**
|
|
874
|
-
* Remove all ANSI escape sequences from a string.
|
|
875
|
-
*
|
|
876
|
-
* Returns the plain-text content with all styling, cursor, and control
|
|
877
|
-
* escape sequences stripped. Useful for computing visible text width,
|
|
878
|
-
* logging plain output, or comparing styled strings by content.
|
|
879
|
-
*
|
|
880
|
-
* @param text - The string potentially containing ANSI escape codes.
|
|
881
|
-
* @returns The string with all ANSI escapes removed.
|
|
882
|
-
*
|
|
883
|
-
* @example
|
|
884
|
-
* ```ts
|
|
885
|
-
* import { stripAnsi } from "./stripAnsi.ts";
|
|
886
|
-
*
|
|
887
|
-
* stripAnsi("\x1b[1mhello\x1b[22m"); // "hello"
|
|
888
|
-
* stripAnsi("no escapes"); // "no escapes"
|
|
889
|
-
* ```
|
|
890
|
-
*/
|
|
891
|
-
declare function stripAnsi(text: string): string;
|
|
892
|
-
/**
|
|
893
874
|
* Compute the visible (column) width of a string.
|
|
894
875
|
*
|
|
895
876
|
* ANSI escape sequences are stripped before measurement. Full-width
|
|
@@ -1144,4 +1125,4 @@ declare function createMarkdownTheme(options?: CreateMarkdownThemeOptions): Mark
|
|
|
1144
1125
|
* ```
|
|
1145
1126
|
*/
|
|
1146
1127
|
declare const defaultTheme: MarkdownTheme;
|
|
1147
|
-
export { yellow as yellowCode, yellow2 as yellow, wrapText, white as whiteCode, white2 as white, visibleWidth, unorderedList, underline as underlineCode, underline2 as underline, taskList, table, style,
|
|
1128
|
+
export { yellow as yellowCode, yellow2 as yellow, wrapText, white as whiteCode, white2 as white, visibleWidth, unorderedList, underline as underlineCode, underline2 as underline, taskList, table, style, strikethrough as strikethroughCode, strikethrough2 as strikethrough, rgbCode, rgb, resolveTrueColor, resolveCapability, reset, red as redCode, red2 as red, parseHex, padStart, padEnd, orderedList, magenta as magentaCode, magenta2 as magenta, italic as italicCode, italic2 as italic, inverse as inverseCode, inverse2 as inverse, hidden as hiddenCode, hidden2 as hidden, hexCode, hex, green as greenCode, green2 as green, gray as grayCode, gray2 as gray, dim as dimCode, dim2 as dim, defaultTheme, cyan as cyanCode, cyan2 as cyan, createStyle, createMarkdownTheme, composeStyles, center, buildDefaultMarkdownTheme, brightYellow as brightYellowCode, brightYellow2 as brightYellow, brightWhite as brightWhiteCode, brightWhite2 as brightWhite, brightRed as brightRedCode, brightRed2 as brightRed, brightMagenta as brightMagentaCode, brightMagenta2 as brightMagenta, brightGreen as brightGreenCode, brightGreen2 as brightGreen, brightCyan as brightCyanCode, brightCyan2 as brightCyan, brightBlue as brightBlueCode, brightBlue2 as brightBlue, bold as boldCode, bold2 as bold, blue as blueCode, blue2 as blue, black as blackCode, black2 as black, bgYellow as bgYellowCode, bgYellow2 as bgYellow, bgWhite as bgWhiteCode, bgWhite2 as bgWhite, bgRgbCode, bgRgb2 as bgRgb, bgRed as bgRedCode, bgRed2 as bgRed, bgMagenta as bgMagentaCode, bgMagenta2 as bgMagenta, bgHexCode, bgHex2 as bgHex, bgGreen as bgGreenCode, bgGreen2 as bgGreen, bgCyan as bgCyanCode, bgCyan2 as bgCyan, bgBrightYellow as bgBrightYellowCode, bgBrightYellow2 as bgBrightYellow, bgBrightWhite as bgBrightWhiteCode, bgBrightWhite2 as bgBrightWhite, bgBrightRed as bgBrightRedCode, bgBrightRed2 as bgBrightRed, bgBrightMagenta as bgBrightMagentaCode, bgBrightMagenta2 as bgBrightMagenta, bgBrightGreen as bgBrightGreenCode, bgBrightGreen2 as bgBrightGreen, bgBrightCyan as bgBrightCyanCode, bgBrightCyan2 as bgBrightCyan, bgBrightBlue as bgBrightBlueCode, bgBrightBlue2 as bgBrightBlue, bgBrightBlack as bgBrightBlackCode, bgBrightBlack2 as bgBrightBlack, bgBlue as bgBlueCode, bgBlue2 as bgBlue, bgBlack as bgBlackCode, bgBlack2 as bgBlack, applyStyle, WrapOptions, UnorderedListOptions, TrueColorOverrides, ThemeSlotFn, TaskListOptions, TaskListItem, TableOptions, StyleOptions, StyleInstance, StyleFn, PartialMarkdownTheme, OrderedListOptions, MarkdownTheme, CreateMarkdownThemeOptions, ColumnAlignment, ColorMode, CapabilityOverrides, AnsiPair };
|
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
var
|
|
3
|
-
`);if(V.length<=1)return z;let $=" ".repeat(Z);return V.map((Q,
|
|
4
|
-
`)}function uz(z,Z){let V=Z?.marker??"\u2022",$=Z?.markerGap??1,Q=Z?.indent??0,
|
|
5
|
-
`)}function xz(z,Z){let V=Z?.start??1,$=Z?.markerGap??1,Q=Z?.indent??0;if(z.length===0)return"";let
|
|
6
|
-
`)}function
|
|
7
|
-
`)}function
|
|
8
|
-
`)}function jz(z,Z){if(z==="always")return!0;if(z==="never")return!1;let
|
|
9
|
-
`),
|
|
10
|
-
`)}function
|
|
2
|
+
var Pz=Object.defineProperty;var bz=(z)=>z;function yz(z,Z){this[z]=bz.bind(null,Z)}var vz=(z,Z)=>{for(var V in Z)Pz(z,V,{get:Z[V],enumerable:!0,configurable:!0,set:yz.bind(Z,V)})};var q={};vz(q,{yellow:()=>C,white:()=>P,underline:()=>L,strikethrough:()=>T,reset:()=>Iz,red:()=>f,magenta:()=>S,italic:()=>E,inverse:()=>I,hidden:()=>N,green:()=>W,gray:()=>b,dim:()=>R,cyan:()=>g,brightYellow:()=>m,brightWhite:()=>h,brightRed:()=>y,brightMagenta:()=>x,brightGreen:()=>v,brightCyan:()=>p,brightBlue:()=>u,bold:()=>M,blue:()=>w,black:()=>k,bgYellow:()=>l,bgWhite:()=>o,bgRed:()=>n,bgMagenta:()=>r,bgGreen:()=>d,bgCyan:()=>a,bgBrightYellow:()=>zz,bgBrightWhite:()=>Qz,bgBrightRed:()=>t,bgBrightMagenta:()=>Zz,bgBrightGreen:()=>e,bgBrightCyan:()=>$z,bgBrightBlue:()=>Vz,bgBrightBlack:()=>i,bgBlue:()=>s,bgBlack:()=>c});function O(z,Z){return{open:`\x1B[${z}m`,close:`\x1B[${Z}m`}}var Iz=O(0,0),M=O(1,22),R=O(2,22),E=O(3,23),L=O(4,24),I=O(7,27),N=O(8,28),T=O(9,29),k=O(30,39),f=O(31,39),W=O(32,39),C=O(33,39),w=O(34,39),S=O(35,39),g=O(36,39),P=O(37,39),b=O(90,39),y=O(91,39),v=O(92,39),m=O(93,39),u=O(94,39),x=O(95,39),p=O(96,39),h=O(97,39),c=O(40,49),n=O(41,49),d=O(42,49),l=O(43,49),s=O(44,49),r=O(45,49),a=O(46,49),o=O(47,49),i=O(100,49),t=O(101,49),e=O(102,49),zz=O(103,49),Vz=O(104,49),Zz=O(105,49),$z=O(106,49),Qz=O(107,49);function mz(z){return z>=19968&&z<=40959||z>=13312&&z<=19903||z>=131072&&z<=173791||z>=63744&&z<=64255||z>=65281&&z<=65376||z>=65504&&z<=65510||z>=11904&&z<=12031||z>=12032&&z<=12255||z>=12288&&z<=12351||z>=12352&&z<=12447||z>=12448&&z<=12543||z>=12544&&z<=12591||z>=12592&&z<=12687||z>=12800&&z<=13055||z>=13056&&z<=13311||z>=44032&&z<=55215||z>=65072&&z<=65103}function D(z){let Z=Bun.stripANSI(z),V=0;for(let $ of Z){let Q=$.codePointAt(0);if(Q===void 0)continue;V+=mz(Q)?2:1}return V}function Kz(z,Z){let V=z.split(`
|
|
3
|
+
`);if(V.length<=1)return z;let $=" ".repeat(Z);return V.map((Q,J)=>J===0?Q:$+Q).join(`
|
|
4
|
+
`)}function uz(z,Z){let V=Z?.marker??"\u2022",$=Z?.markerGap??1,Q=Z?.indent??0,J=" ".repeat(Q),X=" ".repeat($),j=D(V),Y=Q+j+$;return z.map((U)=>{let _=Kz(U,Y);return`${J}${V}${X}${_}`}).join(`
|
|
5
|
+
`)}function xz(z,Z){let V=Z?.start??1,$=Z?.markerGap??1,Q=Z?.indent??0;if(z.length===0)return"";let J=" ".repeat(Q),X=" ".repeat($),Y=`${V+z.length-1}.`.length;return z.map((U,_)=>{let F=`${V+_}.`.padStart(Y," "),Xz=Q+Y+$,G=Kz(U,Xz);return`${J}${F}${X}${G}`}).join(`
|
|
6
|
+
`)}function pz(z,Z){let V=Z?.checkedMarker??"[x]",$=Z?.uncheckedMarker??"[ ]",Q=Z?.markerGap??1,J=Z?.indent??0,X=" ".repeat(J),j=" ".repeat(Q),Y=Math.max(D(V),D($)),U=J+Y+Q;return z.map((_)=>{let H=_.checked?V:$,A=Kz(_.text,U);return`${X}${H}${j}${A}`}).join(`
|
|
7
|
+
`)}function Yz(z,Z,V=" "){let $=D(z);if($>=Z)return z;return V.repeat(Z-$)+z}function Oz(z,Z,V=" "){let $=D(z);if($>=Z)return z;let Q=V.repeat(Z-$);return z+Q}function Uz(z,Z,V=" "){let $=D(z);if($>=Z)return z;let Q=Z-$,J=Math.floor(Q/2),X=Q-J;return V.repeat(J)+z+V.repeat(X)}function hz(z,Z,V){let $=z.length,Q=Array($).fill(V);for(let J=0;J<$;J++){let X=z[J];if(X!==void 0)Q[J]=Math.max(Q[J]??0,D(X))}for(let J of Z)for(let X=0;X<$;X++){let j=J[X];if(j!==void 0)Q[X]=Math.max(Q[X]??0,D(j))}return Q}function cz(z,Z,V){switch(V){case"right":return Yz(z,Z);case"center":return Uz(z,Z);default:return Oz(z,Z)}}function Nz(z,Z,V,$,Q){let J=" ".repeat($),X=Z.map((j,Y)=>{let U=z[Y]??"",_=V[Y]??"left",H=cz(U,j,_);return`${J}${H}${J}`});return`${Q}${X.join(Q)}${Q}`}function nz(z,Z,V,$){let Q=z.map((J)=>{return V.repeat(J+Z*2)});return`${$}${Q.join($)}${$}`}function dz(z,Z,V){let $=V?.align??[],Q=V?.minColumnWidth??0,J=V?.cellPadding??1,X=V?.separatorChar??"-",j=V?.borderChar??"|",Y=hz(z,Z,Q),U=[];U.push(Nz(z,Y,$,J,j)),U.push(nz(Y,J,X,j));for(let _ of Z)U.push(Nz(_,Y,$,J,j));return U.join(`
|
|
8
|
+
`)}function jz(z,Z){if(z==="always")return!0;if(z==="never")return!1;let $=Z!==void 0&&"isTTY"in Z?Z.isTTY??!1:process.stdout?.isTTY??!1;if((Z!==void 0&&"noColor"in Z?Z.noColor:process.env.NO_COLOR)!==void 0)return!1;return $}function _z(z,Z){if(z==="always")return!0;if(z==="never")return!1;if(!jz(z,Z))return!1;let Q=(Z!==void 0&&"colorTerm"in Z?Z.colorTerm:process.env.COLORTERM)?.toLowerCase();if(Q==="truecolor"||Q==="24bit")return!0;let X=Z!==void 0&&"term"in Z?Z.term:process.env.TERM;if(X!==void 0){let j=X.toLowerCase();if(j.includes("24bit")||j.includes("truecolor")||j.endsWith("-direct"))return!0}return!1}function K(z,Z){if(z==="")return"";let{open:V,close:$}=Z;if(z.includes($))z=z.replaceAll($,$+V);return V+z+$}function lz(...z){return{open:z.map((Z)=>Z.open).join(""),close:z.map((Z)=>Z.close).reverse().join("")}}function sz(z){return K(z,k)}function rz(z){return K(z,f)}function az(z){return K(z,W)}function oz(z){return K(z,C)}function iz(z){return K(z,w)}function tz(z){return K(z,S)}function ez(z){return K(z,g)}function zV(z){return K(z,P)}function VV(z){return K(z,b)}function ZV(z){return K(z,y)}function $V(z){return K(z,v)}function QV(z){return K(z,m)}function jV(z){return K(z,u)}function JV(z){return K(z,x)}function XV(z){return K(z,p)}function KV(z){return K(z,h)}function YV(z){return K(z,c)}function OV(z){return K(z,n)}function UV(z){return K(z,d)}function _V(z){return K(z,l)}function DV(z){return K(z,s)}function FV(z){return K(z,r)}function HV(z){return K(z,a)}function GV(z){return K(z,o)}function BV(z){return K(z,i)}function AV(z){return K(z,t)}function qV(z){return K(z,e)}function MV(z){return K(z,zz)}function RV(z){return K(z,Vz)}function EV(z){return K(z,Zz)}function LV(z){return K(z,$z)}function IV(z){return K(z,Qz)}function Dz(z,Z){if(!Number.isInteger(z)||z<0||z>255)throw RangeError(`Invalid ${Z} value: ${String(z)}. Must be an integer between 0 and 255.`)}function Tz(z,Z,V){Dz(z,"red"),Dz(Z,"green"),Dz(V,"blue")}var NV=/^#([0-9a-f]{3})$/i,TV=/^#([0-9a-f]{6})$/i;function Fz(z){let Z=NV.exec(z);if(Z){let $=Z[1],Q=$.charAt(0),J=$.charAt(1),X=$.charAt(2);return[Number.parseInt(Q+Q,16),Number.parseInt(J+J,16),Number.parseInt(X+X,16)]}let V=TV.exec(z);if(V){let $=V[1];return[Number.parseInt($.slice(0,2),16),Number.parseInt($.slice(2,4),16),Number.parseInt($.slice(4,6),16)]}throw TypeError(`Invalid hex color: "${z}". Expected format: "#RGB" or "#RRGGBB".`)}function Hz(z,Z,V){return Tz(z,Z,V),{open:`\x1B[38;2;${z};${Z};${V}m`,close:"\x1B[39m"}}function Gz(z,Z,V){return Tz(z,Z,V),{open:`\x1B[48;2;${z};${Z};${V}m`,close:"\x1B[49m"}}function kz(z){let[Z,V,$]=Fz(z);return Hz(Z,V,$)}function fz(z){let[Z,V,$]=Fz(z);return Gz(Z,V,$)}function Bz(z,Z,V,$){return K(z,Hz(Z,V,$))}function Az(z,Z,V,$){return K(z,Gz(Z,V,$))}function qz(z,Z){return K(z,kz(Z))}function Mz(z,Z){return K(z,fz(Z))}function kV(){let{reset:z,...Z}=q;return Z}var Wz=Object.freeze(kV()),Rz=Object.freeze(Object.keys(Wz));function Cz(z){return Wz[z]}function fV(z,Z,V){if(!V||z==="")return z;let $=z;for(let Q=Z.length-1;Q>=0;Q--){let J=Z[Q];if(J===void 0)continue;$=K($,Cz(J))}return $}function WV(z){let Z=new Map;function V(Q){return Q.join("|")}function $(Q){let J=V(Q),X=Z.get(J);if(X)return X;let j=(Y)=>fV(Y,Q,z);Z.set(J,j);for(let Y of Rz)Object.defineProperty(j,Y,{configurable:!1,enumerable:!0,get(){return $([...Q,Y])}});return Object.freeze(j)}return $}function CV(z){let Z={};for(let V of Rz)Z[V]=z([V]);return Z}function Jz(z){let Z=z?.mode??"auto",V=jz(Z,z?.overrides),$=_z(Z,z?.overrides),Q=WV(V),J=CV(Q),X={enabled:V,trueColorEnabled:$,apply:V?(j,Y)=>K(j,Y):(j,Y)=>j,rgb:$?(j,Y,U,_)=>Bz(j,Y,U,_):(j,Y,U,_)=>j,bgRgb:$?(j,Y,U,_)=>Az(j,Y,U,_):(j,Y,U,_)=>j,hex:$?(j,Y)=>qz(j,Y):(j,Y)=>j,bgHex:$?(j,Y)=>Mz(j,Y):(j,Y)=>j,...J};return Object.freeze(X)}var wV=Jz();function SV(z){return K(z,M)}function gV(z){return K(z,R)}function PV(z){return K(z,E)}function bV(z){return K(z,L)}function yV(z){return K(z,I)}function vV(z){return K(z,N)}function mV(z){return K(z,T)}var uV=/[\x1b\x9b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><~]/;function xV(z){return z>=19968&&z<=40959||z>=13312&&z<=19903||z>=131072&&z<=173791||z>=63744&&z<=64255||z>=65281&&z<=65376||z>=65504&&z<=65510||z>=11904&&z<=12031||z>=12032&&z<=12255||z>=12288&&z<=12351||z>=12352&&z<=12447||z>=12448&&z<=12543||z>=12544&&z<=12591||z>=12592&&z<=12687||z>=12800&&z<=13055||z>=13056&&z<=13311||z>=44032&&z<=55215||z>=65072&&z<=65103}function pV(z){return z==="\x1B[0m"}function hV(z){return z.endsWith("m")&&z.startsWith("\x1B[")}function cV(z,Z,V){if(Z<=0)return z;let $=V?.wordBreak??!0,Q=z.split(`
|
|
9
|
+
`),J=[],X=[];for(let j of Q){let Y=nV(j,Z,$,X);J.push(...Y.lines),X=Y.activeStyles}return J.join(`
|
|
10
|
+
`)}function nV(z,Z,V,$){let Q=[...$],J=[],X=Q.length>0?Q.join(""):"",j=0,Y=-1,U=0,_=[],H=0;while(H<z.length){let A=z.slice(H).match(uV);if(A&&A.index===0){let B=A[0];if(hV(B))if(pV(B))Q.length=0;else Q.push(B);X+=B,H+=B.length;continue}let F=z[H];if(F===void 0)break;let Xz=F.codePointAt(0)??0,G=xV(Xz)?2:1;if(j+G>Z)if(V&&Y!==-1){let B=X.slice(0,Y),Lz=X.slice(Y+1),Sz=Q.length>0?"\x1B[0m":"";if(J.push(B+Sz),X=(_.length>0?_.join(""):"")+Lz,j=j-U,Y=-1,U=0,_=[],j+G>Z){let gz=Q.length>0?"\x1B[0m":"";J.push(X+gz),X=(Q.length>0?Q.join(""):"")+F,j=G}else X+=F,j+=G}else{let B=Q.length>0?"\x1B[0m":"";J.push(X+B),X=(Q.length>0?Q.join(""):"")+F,j=G,Y=-1,U=0,_=[]}else if(V&&F===" ")X+=F,j+=G,Y=X.length-1,U=j,_=[...Q];else X+=F,j+=G;H+=F.length}if(X.length>0){if(X.replace(/[\x1b\x9b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><~]/g,"").length>0||X.length>0)J.push(X)}else J.push("");return{lines:J,activeStyles:Q}}function Ez(z){return Object.freeze({heading1:(V)=>z.bold(z.underline(V)),heading2:(V)=>z.bold(V),heading3:(V)=>z.bold(z.yellow(V)),heading4:(V)=>z.yellow(V),heading5:(V)=>z.dim(z.yellow(V)),heading6:(V)=>z.dim(V),text:(V)=>V,emphasis:(V)=>z.italic(V),strong:(V)=>z.bold(V),strongEmphasis:(V)=>z.bold(z.italic(V)),strikethrough:(V)=>z.strikethrough(V),inlineCode:(V)=>z.cyan(V),linkText:(V)=>z.blue(z.underline(V)),linkUrl:(V)=>z.dim(z.underline(V)),autolink:(V)=>z.blue(z.underline(V)),blockquoteMarker:(V)=>z.dim(z.green(V)),blockquoteText:(V)=>z.italic(V),listMarker:(V)=>z.dim(V),orderedListMarker:(V)=>z.dim(V),taskChecked:(V)=>z.green(V),taskUnchecked:(V)=>z.dim(V),codeFence:(V)=>z.dim(V),codeInfo:(V)=>z.dim(z.italic(V)),codeText:(V)=>z.cyan(V),thematicBreak:(V)=>z.dim(V),tableHeader:(V)=>z.bold(V),tableCell:(V)=>V,tableBorder:(V)=>z.dim(V),imageAltText:(V)=>z.italic(z.magenta(V)),imageUrl:(V)=>z.dim(z.underline(V))})}function wz(z){let Z=Jz(z?.style),V=Ez(Z),$=z?.overrides;if(!$)return V;let Q={heading1:$.heading1??V.heading1,heading2:$.heading2??V.heading2,heading3:$.heading3??V.heading3,heading4:$.heading4??V.heading4,heading5:$.heading5??V.heading5,heading6:$.heading6??V.heading6,text:$.text??V.text,emphasis:$.emphasis??V.emphasis,strong:$.strong??V.strong,strongEmphasis:$.strongEmphasis??V.strongEmphasis,strikethrough:$.strikethrough??V.strikethrough,inlineCode:$.inlineCode??V.inlineCode,linkText:$.linkText??V.linkText,linkUrl:$.linkUrl??V.linkUrl,autolink:$.autolink??V.autolink,blockquoteMarker:$.blockquoteMarker??V.blockquoteMarker,blockquoteText:$.blockquoteText??V.blockquoteText,listMarker:$.listMarker??V.listMarker,orderedListMarker:$.orderedListMarker??V.orderedListMarker,taskChecked:$.taskChecked??V.taskChecked,taskUnchecked:$.taskUnchecked??V.taskUnchecked,codeFence:$.codeFence??V.codeFence,codeInfo:$.codeInfo??V.codeInfo,codeText:$.codeText??V.codeText,thematicBreak:$.thematicBreak??V.thematicBreak,tableHeader:$.tableHeader??V.tableHeader,tableCell:$.tableCell??V.tableCell,tableBorder:$.tableBorder??V.tableBorder,imageAltText:$.imageAltText??V.imageAltText,imageUrl:$.imageUrl??V.imageUrl};return Object.freeze(Q)}var dV=wz();export{C as yellowCode,oz as yellow,cV as wrapText,P as whiteCode,zV as white,D as visibleWidth,uz as unorderedList,L as underlineCode,bV as underline,pz as taskList,dz as table,wV as style,T as strikethroughCode,mV as strikethrough,Hz as rgbCode,Bz as rgb,_z as resolveTrueColor,jz as resolveCapability,Iz as reset,f as redCode,rz as red,Fz as parseHex,Yz as padStart,Oz as padEnd,xz as orderedList,S as magentaCode,tz as magenta,E as italicCode,PV as italic,I as inverseCode,yV as inverse,N as hiddenCode,vV as hidden,kz as hexCode,qz as hex,W as greenCode,az as green,b as grayCode,VV as gray,R as dimCode,gV as dim,dV as defaultTheme,g as cyanCode,ez as cyan,Jz as createStyle,wz as createMarkdownTheme,lz as composeStyles,Uz as center,Ez as buildDefaultMarkdownTheme,m as brightYellowCode,QV as brightYellow,h as brightWhiteCode,KV as brightWhite,y as brightRedCode,ZV as brightRed,x as brightMagentaCode,JV as brightMagenta,v as brightGreenCode,$V as brightGreen,p as brightCyanCode,XV as brightCyan,u as brightBlueCode,jV as brightBlue,M as boldCode,SV as bold,w as blueCode,iz as blue,k as blackCode,sz as black,l as bgYellowCode,_V as bgYellow,o as bgWhiteCode,GV as bgWhite,Gz as bgRgbCode,Az as bgRgb,n as bgRedCode,OV as bgRed,r as bgMagentaCode,FV as bgMagenta,fz as bgHexCode,Mz as bgHex,d as bgGreenCode,UV as bgGreen,a as bgCyanCode,HV as bgCyan,zz as bgBrightYellowCode,MV as bgBrightYellow,Qz as bgBrightWhiteCode,IV as bgBrightWhite,t as bgBrightRedCode,AV as bgBrightRed,Zz as bgBrightMagentaCode,EV as bgBrightMagenta,e as bgBrightGreenCode,qV as bgBrightGreen,$z as bgBrightCyanCode,LV as bgBrightCyan,Vz as bgBrightBlueCode,RV as bgBrightBlue,i as bgBrightBlackCode,BV as bgBrightBlack,s as bgBlueCode,DV as bgBlue,c as bgBlackCode,YV as bgBlack,K as applyStyle};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@crustjs/style",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.6",
|
|
4
4
|
"description": "Terminal styling foundation for the Crust CLI framework",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -39,11 +39,12 @@
|
|
|
39
39
|
"build": "bunup",
|
|
40
40
|
"dev": "bunup --watch",
|
|
41
41
|
"check:types": "tsc --noEmit",
|
|
42
|
-
"test": "bun test"
|
|
42
|
+
"test": "bun test",
|
|
43
|
+
"publish": "bun publish --no-git-checks || true"
|
|
43
44
|
},
|
|
44
45
|
"devDependencies": {
|
|
45
46
|
"@crustjs/config": "0.0.0",
|
|
46
|
-
"bunup": "^0.16.
|
|
47
|
+
"bunup": "^0.16.31"
|
|
47
48
|
},
|
|
48
49
|
"peerDependencies": {
|
|
49
50
|
"typescript": "^5"
|