summit-marker 3.0.1 → 3.0.2
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 +250 -427
- package/package.json +2 -2
- package/src/backgrounds.js +16 -0
- package/src/errors.js +34 -0
- package/src/index.js +39 -9
- package/src/logger.js +65 -0
- package/src/spinner.js +83 -0
- package/src/table.js +57 -0
- package/LICENSE +0 -47
package/README.md
CHANGED
|
@@ -7,106 +7,112 @@
|
|
|
7
7
|
|
|
8
8
|

|
|
9
9
|
|
|
10
|
-
# Marker
|
|
11
|
-
|
|
12
10
|
A zero-dependency terminal styling and CLI presentation toolkit for Node.js.
|
|
13
11
|
|
|
14
|
-
Marker
|
|
12
|
+
Marker gives developers everything needed to create beautiful terminal applications without installing multiple packages.
|
|
13
|
+
|
|
14
|
+
Built by **Summit**.
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
# Features
|
|
15
19
|
|
|
16
|
-
-
|
|
17
|
-
-
|
|
18
|
-
- RGB
|
|
19
|
-
-
|
|
20
|
+
- Terminal colors
|
|
21
|
+
- Text styles
|
|
22
|
+
- RGB colors
|
|
23
|
+
- Full HEX colors
|
|
20
24
|
- True RGB gradients
|
|
21
25
|
- Gradient presets
|
|
22
26
|
- Themes
|
|
23
|
-
-
|
|
24
|
-
-
|
|
27
|
+
- Terminal boxes
|
|
28
|
+
- Styled messages
|
|
25
29
|
- Symbols
|
|
26
30
|
- Text utilities
|
|
27
|
-
- Progress
|
|
31
|
+
- Progress bars
|
|
32
|
+
- Spinners
|
|
33
|
+
- Tables
|
|
34
|
+
- Logger system
|
|
28
35
|
- Terminal detection
|
|
29
|
-
|
|
30
|
-
Built by **Summit**.
|
|
36
|
+
- Developer utilities
|
|
31
37
|
|
|
32
38
|
---
|
|
33
39
|
|
|
34
40
|
# Why Marker?
|
|
35
41
|
|
|
36
|
-
|
|
42
|
+
Most terminal applications need multiple libraries for:
|
|
37
43
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
- terminal colors
|
|
41
|
-
- message formatting
|
|
42
|
-
- boxes
|
|
44
|
+
- colors
|
|
45
|
+
- formatting
|
|
43
46
|
- symbols
|
|
44
|
-
-
|
|
45
|
-
-
|
|
47
|
+
- loading states
|
|
48
|
+
- tables
|
|
49
|
+
- logging
|
|
50
|
+
- CLI presentation
|
|
46
51
|
|
|
47
52
|
Marker combines these features into one lightweight package.
|
|
48
53
|
|
|
49
|
-
Instead of
|
|
54
|
+
Instead of:
|
|
50
55
|
|
|
51
56
|
```js
|
|
52
57
|
"\x1b[31mError\x1b[0m"
|
|
53
|
-
```
|
|
54
58
|
|
|
55
59
|
You can write:
|
|
56
60
|
|
|
57
|
-
```js
|
|
58
61
|
marker.red("Error");
|
|
59
|
-
```
|
|
60
62
|
|
|
61
|
-
|
|
63
|
+
or:
|
|
62
64
|
|
|
63
|
-
```js
|
|
64
65
|
marker.error("Build failed");
|
|
65
|
-
```
|
|
66
66
|
|
|
67
67
|
Marker focuses on:
|
|
68
68
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
69
|
+
simple APIs
|
|
70
|
+
|
|
71
|
+
zero dependencies
|
|
72
|
+
|
|
73
|
+
cross-platform support
|
|
74
|
+
|
|
75
|
+
fast installation
|
|
76
|
+
|
|
77
|
+
beautiful CLI output
|
|
73
78
|
|
|
74
|
-
---
|
|
75
79
|
|
|
76
|
-
# Marker vs Chalk
|
|
77
|
-
|
|
78
|
-
| Feature | Marker | Chalk |
|
|
79
|
-
|---|---|---|
|
|
80
|
-
| Colors | ✅ | ✅ |
|
|
81
|
-
| Styles | ✅ | ✅ |
|
|
82
|
-
| RGB | ✅ | ✅ |
|
|
83
|
-
| Hex colors | ✅ | ❌ |
|
|
84
|
-
| True RGB gradients | ✅ | ❌ |
|
|
85
|
-
| Gradient presets | ✅ | ❌ |
|
|
86
|
-
| Themes | ✅ | ❌ |
|
|
87
|
-
| Box formatting | ✅ | ❌ |
|
|
88
|
-
| Built-in messages | ✅ | ❌ |
|
|
89
|
-
| Symbols API | ✅ | ❌ |
|
|
90
|
-
| Text utilities | ✅ | ❌ |
|
|
91
|
-
| Zero dependencies | ✅ | Depends on version |
|
|
92
|
-
|
|
93
|
-
Marker is designed as a complete terminal presentation toolkit.
|
|
94
80
|
|
|
95
81
|
---
|
|
96
82
|
|
|
97
|
-
|
|
83
|
+
Marker vs Chalk
|
|
84
|
+
|
|
85
|
+
Feature Marker Chalk
|
|
86
|
+
|
|
87
|
+
Colors ✅ ✅
|
|
88
|
+
Styles ✅ ✅
|
|
89
|
+
RGB ✅ ✅
|
|
90
|
+
HEX colors ✅ ❌
|
|
91
|
+
True RGB gradients ✅ ❌
|
|
92
|
+
Gradient presets ✅ ❌
|
|
93
|
+
Themes ✅ ❌
|
|
94
|
+
Boxes ✅ ❌
|
|
95
|
+
Messages ✅ ❌
|
|
96
|
+
Symbols ✅ ❌
|
|
97
|
+
Text utilities ✅ ❌
|
|
98
|
+
Spinners ✅ ❌
|
|
99
|
+
Tables ✅ ❌
|
|
100
|
+
Logger ✅ ❌
|
|
101
|
+
Dependencies 0 Depends
|
|
102
|
+
|
|
103
|
+
|
|
98
104
|
|
|
99
|
-
|
|
105
|
+
---
|
|
106
|
+
|
|
107
|
+
Installation
|
|
100
108
|
|
|
101
|
-
```bash
|
|
102
109
|
npm install summit-marker
|
|
103
|
-
|
|
110
|
+
|
|
104
111
|
|
|
105
112
|
---
|
|
106
113
|
|
|
107
|
-
|
|
114
|
+
Quick Start
|
|
108
115
|
|
|
109
|
-
```js
|
|
110
116
|
import marker from "summit-marker";
|
|
111
117
|
|
|
112
118
|
console.log(
|
|
@@ -120,25 +126,18 @@ console.log(
|
|
|
120
126
|
console.log(
|
|
121
127
|
marker.success("Installed")
|
|
122
128
|
);
|
|
123
|
-
```
|
|
124
129
|
|
|
125
130
|
Output:
|
|
126
131
|
|
|
127
|
-
```
|
|
128
132
|
Success
|
|
129
133
|
Hello Marker
|
|
130
134
|
✔ Installed
|
|
131
|
-
```
|
|
132
135
|
|
|
133
|
-
---
|
|
134
|
-
|
|
135
|
-
# API Documentation
|
|
136
136
|
|
|
137
|
-
|
|
137
|
+
---
|
|
138
138
|
|
|
139
|
-
|
|
139
|
+
Colors
|
|
140
140
|
|
|
141
|
-
```js
|
|
142
141
|
marker.red("Red");
|
|
143
142
|
|
|
144
143
|
marker.green("Green");
|
|
@@ -149,235 +148,103 @@ marker.orange("Orange");
|
|
|
149
148
|
|
|
150
149
|
marker.pink("Pink");
|
|
151
150
|
|
|
152
|
-
marker.brown("Brown");
|
|
153
|
-
|
|
154
151
|
marker.neon("Neon");
|
|
155
|
-
```
|
|
156
|
-
|
|
157
|
-
Additional colors:
|
|
158
|
-
|
|
159
|
-
```js
|
|
160
|
-
marker.gold("Gold");
|
|
161
|
-
|
|
162
|
-
marker.lime("Lime");
|
|
163
|
-
|
|
164
|
-
marker.teal("Teal");
|
|
165
152
|
|
|
166
|
-
marker.violet("Violet");
|
|
167
|
-
|
|
168
|
-
marker.magenta("Magenta");
|
|
169
|
-
|
|
170
|
-
marker.navy("Navy");
|
|
171
|
-
|
|
172
|
-
marker.skyBlue("Sky Blue");
|
|
173
|
-
|
|
174
|
-
marker.emerald("Emerald");
|
|
175
|
-
```
|
|
176
153
|
|
|
177
154
|
---
|
|
178
155
|
|
|
179
|
-
|
|
156
|
+
Styles
|
|
180
157
|
|
|
181
|
-
Marker includes text styles:
|
|
182
|
-
|
|
183
|
-
```js
|
|
184
158
|
marker.bold("Bold");
|
|
185
159
|
|
|
186
160
|
marker.italic("Italic");
|
|
187
161
|
|
|
188
162
|
marker.underline("Underline");
|
|
189
|
-
```
|
|
190
163
|
|
|
191
|
-
|
|
164
|
+
Combine styles:
|
|
192
165
|
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
marker.underline.blue("Documentation");
|
|
197
|
-
```
|
|
198
|
-
|
|
199
|
-
---
|
|
200
|
-
|
|
201
|
-
# Chaining
|
|
202
|
-
|
|
203
|
-
Marker uses a chainable API:
|
|
204
|
-
|
|
205
|
-
```js
|
|
206
|
-
marker
|
|
207
|
-
.bold
|
|
208
|
-
.green
|
|
209
|
-
("Success");
|
|
210
|
-
```
|
|
211
|
-
|
|
212
|
-
Example:
|
|
213
|
-
|
|
214
|
-
```js
|
|
215
|
-
marker.bold.red.underline(
|
|
216
|
-
"Important"
|
|
166
|
+
marker.bold.red(
|
|
167
|
+
"Critical Error"
|
|
217
168
|
);
|
|
218
|
-
|
|
169
|
+
|
|
219
170
|
|
|
220
171
|
---
|
|
221
172
|
|
|
222
|
-
|
|
173
|
+
RGB
|
|
223
174
|
|
|
224
|
-
Marker supports true 24-bit RGB
|
|
175
|
+
Marker supports true 24-bit RGB.
|
|
225
176
|
|
|
226
177
|
That means:
|
|
227
178
|
|
|
228
|
-
```
|
|
229
179
|
16,777,216 possible colors
|
|
230
|
-
```
|
|
231
180
|
|
|
232
181
|
Example:
|
|
233
182
|
|
|
234
|
-
```js
|
|
235
183
|
marker.rgb(
|
|
236
184
|
255,
|
|
237
185
|
120,
|
|
238
186
|
0
|
|
239
|
-
)(
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
---
|
|
243
|
-
|
|
244
|
-
# Hex Colors
|
|
245
|
-
|
|
246
|
-
Use any HEX color:
|
|
187
|
+
)(
|
|
188
|
+
"Orange"
|
|
189
|
+
);
|
|
247
190
|
|
|
248
|
-
```js
|
|
249
|
-
marker.hex("#ff8800")
|
|
250
|
-
("Orange");
|
|
251
|
-
```
|
|
252
191
|
|
|
253
|
-
|
|
192
|
+
---
|
|
254
193
|
|
|
255
|
-
|
|
256
|
-
marker.hex("#ff0000")
|
|
257
|
-
("Red");
|
|
194
|
+
HEX Colors
|
|
258
195
|
|
|
259
|
-
marker.hex(
|
|
260
|
-
|
|
196
|
+
marker.hex(
|
|
197
|
+
"#ff8800"
|
|
198
|
+
)(
|
|
199
|
+
"Orange"
|
|
200
|
+
);
|
|
261
201
|
|
|
262
|
-
marker.hex("#0000ff")
|
|
263
|
-
("Blue");
|
|
264
|
-
```
|
|
265
202
|
|
|
266
203
|
---
|
|
267
204
|
|
|
268
|
-
|
|
205
|
+
Gradients
|
|
269
206
|
|
|
270
|
-
|
|
207
|
+
Basic gradient:
|
|
271
208
|
|
|
272
|
-
## Basic Gradient
|
|
273
|
-
|
|
274
|
-
```js
|
|
275
209
|
marker.gradient(
|
|
276
210
|
"SUMMIT"
|
|
277
211
|
);
|
|
278
|
-
```
|
|
279
212
|
|
|
280
|
-
|
|
213
|
+
True RGB gradient:
|
|
281
214
|
|
|
282
|
-
# True RGB Gradients
|
|
283
|
-
|
|
284
|
-
Marker supports full RGB gradients:
|
|
285
|
-
|
|
286
|
-
```js
|
|
287
215
|
marker.rgbGradient(
|
|
288
216
|
"SUMMIT"
|
|
289
217
|
);
|
|
290
|
-
```
|
|
291
|
-
|
|
292
|
-
Unlike limited terminal palettes, RGB gradients use true color output.
|
|
293
|
-
|
|
294
|
-
---
|
|
295
|
-
|
|
296
|
-
# Gradient Presets
|
|
297
218
|
|
|
298
|
-
|
|
219
|
+
Gradient presets:
|
|
299
220
|
|
|
300
|
-
## Rainbow
|
|
301
|
-
|
|
302
|
-
```js
|
|
303
221
|
marker.gradients.rainbow(
|
|
304
|
-
"
|
|
222
|
+
"Rainbow"
|
|
305
223
|
);
|
|
306
|
-
```
|
|
307
|
-
|
|
308
|
-
## Sunset
|
|
309
224
|
|
|
310
|
-
```js
|
|
311
225
|
marker.gradients.sunset(
|
|
312
|
-
"
|
|
226
|
+
"Sunset"
|
|
313
227
|
);
|
|
314
|
-
```
|
|
315
|
-
|
|
316
|
-
## Ocean
|
|
317
228
|
|
|
318
|
-
```js
|
|
319
229
|
marker.gradients.ocean(
|
|
320
|
-
"
|
|
230
|
+
"Ocean"
|
|
321
231
|
);
|
|
322
|
-
```
|
|
323
232
|
|
|
324
|
-
## Fire
|
|
325
|
-
|
|
326
|
-
```js
|
|
327
233
|
marker.gradients.fire(
|
|
328
|
-
"
|
|
234
|
+
"Fire"
|
|
329
235
|
);
|
|
330
|
-
```
|
|
331
236
|
|
|
332
|
-
## Neon
|
|
333
|
-
|
|
334
|
-
```js
|
|
335
237
|
marker.gradients.neon(
|
|
336
|
-
"
|
|
337
|
-
);
|
|
338
|
-
```
|
|
339
|
-
|
|
340
|
-
## Candy
|
|
341
|
-
|
|
342
|
-
```js
|
|
343
|
-
marker.gradients.candy(
|
|
344
|
-
"CANDY"
|
|
238
|
+
"Neon"
|
|
345
239
|
);
|
|
346
|
-
```
|
|
347
|
-
|
|
348
|
-
## Forest
|
|
349
240
|
|
|
350
|
-
```js
|
|
351
|
-
marker.gradients.forest(
|
|
352
|
-
"FOREST"
|
|
353
|
-
);
|
|
354
|
-
```
|
|
355
|
-
|
|
356
|
-
## Ice
|
|
357
|
-
|
|
358
|
-
```js
|
|
359
|
-
marker.gradients.ice(
|
|
360
|
-
"ICE"
|
|
361
|
-
);
|
|
362
|
-
```
|
|
363
|
-
|
|
364
|
-
## Space
|
|
365
|
-
|
|
366
|
-
```js
|
|
367
|
-
marker.gradients.space(
|
|
368
|
-
"SPACE"
|
|
369
|
-
);
|
|
370
|
-
```
|
|
371
241
|
|
|
372
242
|
---
|
|
373
243
|
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
Marker supports themes for consistent application styling.
|
|
244
|
+
Themes
|
|
377
245
|
|
|
378
|
-
|
|
246
|
+
Create reusable terminal styles.
|
|
379
247
|
|
|
380
|
-
```js
|
|
381
248
|
const theme =
|
|
382
249
|
marker.themes.default;
|
|
383
250
|
|
|
@@ -388,290 +255,268 @@ theme.primary(
|
|
|
388
255
|
theme.success(
|
|
389
256
|
"Success"
|
|
390
257
|
);
|
|
391
|
-
```
|
|
392
258
|
|
|
393
|
-
Themes allow applications to define reusable styles.
|
|
394
259
|
|
|
395
260
|
---
|
|
396
261
|
|
|
397
|
-
|
|
262
|
+
Boxes
|
|
398
263
|
|
|
399
264
|
Create terminal boxes:
|
|
400
265
|
|
|
401
|
-
```js
|
|
402
266
|
marker.box(
|
|
403
267
|
"Hello Marker"
|
|
404
268
|
);
|
|
405
|
-
```
|
|
406
269
|
|
|
407
270
|
Example:
|
|
408
271
|
|
|
409
|
-
```
|
|
410
272
|
┌──────────────┐
|
|
411
273
|
│ Hello Marker │
|
|
412
274
|
└──────────────┘
|
|
413
|
-
```
|
|
414
275
|
|
|
415
|
-
---
|
|
416
276
|
|
|
417
|
-
|
|
277
|
+
---
|
|
418
278
|
|
|
419
|
-
|
|
279
|
+
Messages
|
|
420
280
|
|
|
421
|
-
|
|
281
|
+
Success
|
|
422
282
|
|
|
423
|
-
```js
|
|
424
283
|
marker.success(
|
|
425
|
-
"
|
|
284
|
+
"Build complete"
|
|
426
285
|
);
|
|
427
|
-
```
|
|
428
286
|
|
|
429
287
|
Output:
|
|
430
288
|
|
|
431
|
-
|
|
432
|
-
✔ Installed
|
|
433
|
-
```
|
|
434
|
-
|
|
435
|
-
---
|
|
289
|
+
✔ Build complete
|
|
436
290
|
|
|
437
|
-
|
|
291
|
+
Error
|
|
438
292
|
|
|
439
|
-
```js
|
|
440
293
|
marker.error(
|
|
441
|
-
"
|
|
294
|
+
"Build failed"
|
|
442
295
|
);
|
|
443
|
-
```
|
|
444
296
|
|
|
445
297
|
Output:
|
|
446
298
|
|
|
447
|
-
|
|
448
|
-
✖ Failed
|
|
449
|
-
```
|
|
450
|
-
|
|
451
|
-
---
|
|
299
|
+
✖ Build failed
|
|
452
300
|
|
|
453
|
-
|
|
301
|
+
Warning
|
|
454
302
|
|
|
455
|
-
```js
|
|
456
303
|
marker.warning(
|
|
457
304
|
"Deprecated"
|
|
458
305
|
);
|
|
459
|
-
```
|
|
460
306
|
|
|
461
307
|
Output:
|
|
462
308
|
|
|
463
|
-
```
|
|
464
309
|
⚠ Deprecated
|
|
465
|
-
```
|
|
466
|
-
|
|
467
|
-
---
|
|
468
310
|
|
|
469
|
-
|
|
311
|
+
Info
|
|
470
312
|
|
|
471
|
-
```js
|
|
472
313
|
marker.info(
|
|
473
314
|
"Searching"
|
|
474
315
|
);
|
|
475
|
-
```
|
|
476
316
|
|
|
477
317
|
Output:
|
|
478
318
|
|
|
479
|
-
```
|
|
480
319
|
ℹ Searching
|
|
481
|
-
```
|
|
482
320
|
|
|
483
|
-
---
|
|
484
321
|
|
|
485
|
-
|
|
322
|
+
---
|
|
486
323
|
|
|
487
|
-
|
|
324
|
+
Symbols
|
|
488
325
|
|
|
489
|
-
|
|
490
|
-
marker.symbols.success
|
|
491
|
-
```
|
|
326
|
+
marker.symbols.success;
|
|
492
327
|
|
|
493
|
-
|
|
328
|
+
marker.symbols.error;
|
|
494
329
|
|
|
495
|
-
|
|
496
|
-
✔
|
|
497
|
-
```
|
|
330
|
+
marker.symbols.loading;
|
|
498
331
|
|
|
499
332
|
Available symbols:
|
|
500
333
|
|
|
501
|
-
|
|
502
|
-
|
|
334
|
+
check
|
|
335
|
+
cross
|
|
336
|
+
star
|
|
337
|
+
arrowRight
|
|
338
|
+
loading
|
|
339
|
+
block
|
|
503
340
|
|
|
504
|
-
marker.symbols.cross
|
|
505
341
|
|
|
506
|
-
|
|
342
|
+
---
|
|
507
343
|
|
|
508
|
-
|
|
344
|
+
Text Utilities
|
|
509
345
|
|
|
510
|
-
|
|
346
|
+
CAPS:
|
|
511
347
|
|
|
512
|
-
marker.
|
|
513
|
-
|
|
348
|
+
marker.caps(
|
|
349
|
+
"hello marker"
|
|
350
|
+
);
|
|
514
351
|
|
|
515
|
-
|
|
352
|
+
Lowercase:
|
|
516
353
|
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
- terminal tools
|
|
354
|
+
marker.lower(
|
|
355
|
+
"HELLO"
|
|
356
|
+
);
|
|
521
357
|
|
|
522
|
-
|
|
358
|
+
Title case:
|
|
359
|
+
|
|
360
|
+
marker.title(
|
|
361
|
+
"hello marker"
|
|
362
|
+
);
|
|
523
363
|
|
|
524
|
-
# Text Utilities
|
|
525
364
|
|
|
526
|
-
|
|
365
|
+
---
|
|
527
366
|
|
|
528
|
-
|
|
367
|
+
Progress
|
|
529
368
|
|
|
530
|
-
|
|
531
|
-
marker.caps(
|
|
532
|
-
"hello marker"
|
|
533
|
-
);
|
|
534
|
-
```
|
|
369
|
+
Marker supports terminal progress displays.
|
|
535
370
|
|
|
536
|
-
|
|
371
|
+
Example:
|
|
372
|
+
|
|
373
|
+
████████░░ 80%
|
|
537
374
|
|
|
538
|
-
```
|
|
539
|
-
HELLO MARKER
|
|
540
|
-
```
|
|
541
375
|
|
|
542
376
|
---
|
|
543
377
|
|
|
544
|
-
|
|
378
|
+
Spinners
|
|
545
379
|
|
|
546
|
-
|
|
547
|
-
marker.lower(
|
|
548
|
-
"HELLO"
|
|
549
|
-
);
|
|
550
|
-
```
|
|
380
|
+
Marker includes npm-style loading spinners.
|
|
551
381
|
|
|
552
|
-
|
|
382
|
+
Example:
|
|
553
383
|
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
384
|
+
const spinner =
|
|
385
|
+
marker.spinner(
|
|
386
|
+
"Installing"
|
|
387
|
+
);
|
|
557
388
|
|
|
558
|
-
|
|
389
|
+
spinner.start();
|
|
559
390
|
|
|
560
|
-
|
|
391
|
+
setTimeout(() => {
|
|
392
|
+
spinner.success(
|
|
393
|
+
"Installed"
|
|
394
|
+
);
|
|
395
|
+
}, 2000);
|
|
561
396
|
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
397
|
+
Useful for:
|
|
398
|
+
|
|
399
|
+
installers
|
|
400
|
+
|
|
401
|
+
build tools
|
|
402
|
+
|
|
403
|
+
package managers
|
|
404
|
+
|
|
405
|
+
CLI applications
|
|
567
406
|
|
|
568
|
-
Output:
|
|
569
407
|
|
|
570
|
-
```
|
|
571
|
-
Hello Marker
|
|
572
|
-
```
|
|
573
408
|
|
|
574
409
|
---
|
|
575
410
|
|
|
576
|
-
|
|
411
|
+
Tables
|
|
577
412
|
|
|
578
|
-
|
|
413
|
+
Create terminal tables:
|
|
579
414
|
|
|
580
|
-
|
|
415
|
+
marker.table([
|
|
416
|
+
[
|
|
417
|
+
"Package",
|
|
418
|
+
"Status"
|
|
419
|
+
],
|
|
420
|
+
[
|
|
421
|
+
"Marker",
|
|
422
|
+
"Ready"
|
|
423
|
+
]
|
|
424
|
+
]);
|
|
581
425
|
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
426
|
+
Useful for:
|
|
427
|
+
|
|
428
|
+
dashboards
|
|
429
|
+
|
|
430
|
+
reports
|
|
431
|
+
|
|
432
|
+
developer tools
|
|
585
433
|
|
|
586
|
-
Characters:
|
|
587
434
|
|
|
588
|
-
```
|
|
589
|
-
█ Filled
|
|
590
|
-
░ Empty
|
|
591
|
-
```
|
|
592
435
|
|
|
593
436
|
---
|
|
594
437
|
|
|
595
|
-
|
|
438
|
+
Logger
|
|
596
439
|
|
|
597
|
-
Marker
|
|
440
|
+
Marker includes a developer-focused logger.
|
|
441
|
+
|
|
442
|
+
marker.logger.info(
|
|
443
|
+
"Starting server"
|
|
444
|
+
);
|
|
445
|
+
|
|
446
|
+
marker.logger.success(
|
|
447
|
+
"Connected"
|
|
448
|
+
);
|
|
449
|
+
|
|
450
|
+
marker.logger.warning(
|
|
451
|
+
"Using fallback"
|
|
452
|
+
);
|
|
453
|
+
|
|
454
|
+
marker.logger.error(
|
|
455
|
+
"Failed"
|
|
456
|
+
);
|
|
457
|
+
|
|
458
|
+
Logger levels:
|
|
459
|
+
|
|
460
|
+
info
|
|
461
|
+
success
|
|
462
|
+
warning
|
|
463
|
+
error
|
|
464
|
+
debug
|
|
465
|
+
|
|
466
|
+
|
|
467
|
+
---
|
|
468
|
+
|
|
469
|
+
Terminal Detection
|
|
598
470
|
|
|
599
|
-
```js
|
|
600
471
|
marker.level;
|
|
601
472
|
|
|
602
473
|
marker.supportsColor;
|
|
603
|
-
```
|
|
604
474
|
|
|
605
475
|
Levels:
|
|
606
476
|
|
|
607
|
-
```
|
|
608
477
|
0 - Disabled
|
|
609
478
|
1 - Basic colors
|
|
610
479
|
2 - 256 colors
|
|
611
480
|
3 - True RGB
|
|
612
|
-
|
|
481
|
+
|
|
613
482
|
|
|
614
483
|
---
|
|
615
484
|
|
|
616
|
-
|
|
485
|
+
Environment Variables
|
|
617
486
|
|
|
618
487
|
Disable colors:
|
|
619
488
|
|
|
620
|
-
```bash
|
|
621
489
|
NO_COLOR=1 node app.js
|
|
622
|
-
```
|
|
623
490
|
|
|
624
491
|
Force colors:
|
|
625
492
|
|
|
626
|
-
```bash
|
|
627
493
|
FORCE_COLOR=3 node app.js
|
|
628
|
-
```
|
|
629
494
|
|
|
630
|
-
---
|
|
631
|
-
|
|
632
|
-
# TypeScript
|
|
633
|
-
|
|
634
|
-
Marker includes TypeScript support.
|
|
635
495
|
|
|
636
|
-
|
|
637
|
-
import marker from "summit-marker";
|
|
496
|
+
---
|
|
638
497
|
|
|
639
|
-
|
|
640
|
-
"Hello TypeScript"
|
|
641
|
-
);
|
|
498
|
+
Zero Dependencies
|
|
642
499
|
|
|
643
|
-
|
|
644
|
-
255,
|
|
645
|
-
0,
|
|
646
|
-
0
|
|
647
|
-
)(
|
|
648
|
-
"Red"
|
|
649
|
-
);
|
|
650
|
-
```
|
|
500
|
+
Marker uses:
|
|
651
501
|
|
|
652
|
-
|
|
502
|
+
Dependencies: 0
|
|
653
503
|
|
|
654
|
-
|
|
504
|
+
Benefits:
|
|
655
505
|
|
|
656
|
-
|
|
506
|
+
smaller installs
|
|
657
507
|
|
|
658
|
-
|
|
659
|
-
node examples/BestColors.js
|
|
508
|
+
fewer security risks
|
|
660
509
|
|
|
661
|
-
|
|
510
|
+
faster setup
|
|
662
511
|
|
|
663
|
-
|
|
512
|
+
fewer dependency conflicts
|
|
664
513
|
|
|
665
|
-
node examples/themes.js
|
|
666
514
|
|
|
667
|
-
node examples/progress.js
|
|
668
|
-
```
|
|
669
515
|
|
|
670
516
|
---
|
|
671
517
|
|
|
672
|
-
|
|
518
|
+
Project Structure
|
|
673
519
|
|
|
674
|
-
```
|
|
675
520
|
summit-marker/
|
|
676
521
|
│
|
|
677
522
|
├── src/
|
|
@@ -680,93 +525,71 @@ summit-marker/
|
|
|
680
525
|
│ ├── styles.js
|
|
681
526
|
│ ├── messages.js
|
|
682
527
|
│ ├── gradients.js
|
|
683
|
-
│ ├── rgbGradient.js
|
|
684
528
|
│ ├── themes.js
|
|
685
529
|
│ ├── box.js
|
|
686
|
-
│
|
|
530
|
+
│ ├── text.js
|
|
531
|
+
│ ├── spinner.js
|
|
532
|
+
│ ├── table.js
|
|
533
|
+
│ └── logger.js
|
|
687
534
|
│
|
|
688
535
|
├── examples/
|
|
689
|
-
│ ├── BestColors.js
|
|
690
|
-
│ ├── symbols.js
|
|
691
|
-
│ ├── gradients.js
|
|
692
|
-
│ ├── themes.js
|
|
693
|
-
│ └── progress.js
|
|
694
|
-
│
|
|
695
536
|
├── README.md
|
|
537
|
+
├── EULA.md
|
|
696
538
|
└── package.json
|
|
697
|
-
|
|
539
|
+
|
|
698
540
|
|
|
699
541
|
---
|
|
700
542
|
|
|
701
|
-
|
|
543
|
+
Changelog
|
|
702
544
|
|
|
703
|
-
|
|
545
|
+
3.0.2
|
|
704
546
|
|
|
705
|
-
|
|
547
|
+
Added:
|
|
706
548
|
|
|
707
|
-
|
|
549
|
+
Spinner system
|
|
708
550
|
|
|
709
|
-
|
|
710
|
-
Dependencies: 0
|
|
711
|
-
```
|
|
551
|
+
Terminal tables
|
|
712
552
|
|
|
713
|
-
|
|
553
|
+
Logger utilities
|
|
714
554
|
|
|
715
|
-
|
|
716
|
-
- fewer security risks
|
|
717
|
-
- faster setup
|
|
718
|
-
- fewer dependency conflicts
|
|
555
|
+
Developer utilities
|
|
719
556
|
|
|
720
|
-
|
|
557
|
+
Improved CLI output
|
|
721
558
|
|
|
722
|
-
# Roadmap
|
|
723
559
|
|
|
724
|
-
|
|
560
|
+
3.0.0
|
|
725
561
|
|
|
726
|
-
|
|
727
|
-
- More terminal helpers
|
|
728
|
-
- Advanced progress systems
|
|
729
|
-
- More formatting utilities
|
|
730
|
-
- API improvements
|
|
731
|
-
- Additional CLI features
|
|
562
|
+
Added:
|
|
732
563
|
|
|
733
|
-
|
|
564
|
+
Theme system
|
|
734
565
|
|
|
735
|
-
|
|
566
|
+
Gradient presets
|
|
736
567
|
|
|
737
|
-
|
|
568
|
+
True RGB gradients
|
|
738
569
|
|
|
739
|
-
|
|
570
|
+
Box formatting
|
|
740
571
|
|
|
741
|
-
|
|
742
|
-
- Gradient presets
|
|
743
|
-
- True RGB gradients
|
|
744
|
-
- Box formatting
|
|
745
|
-
- Text utilities
|
|
746
|
-
- Expanded symbols
|
|
747
|
-
- Improved CLI presentation
|
|
572
|
+
Text utilities
|
|
748
573
|
|
|
749
|
-
|
|
574
|
+
Expanded symbols
|
|
750
575
|
|
|
751
|
-
Initial release:
|
|
752
576
|
|
|
753
|
-
- Colors
|
|
754
|
-
- Styles
|
|
755
|
-
- RGB
|
|
756
|
-
- Hex
|
|
757
|
-
- Gradients
|
|
758
|
-
- Messages
|
|
759
577
|
|
|
760
578
|
---
|
|
761
579
|
|
|
762
|
-
|
|
580
|
+
License
|
|
581
|
+
|
|
582
|
+
Marker is licensed under the Summit EULA.
|
|
583
|
+
|
|
584
|
+
See:
|
|
585
|
+
|
|
586
|
+
EULA.md
|
|
763
587
|
|
|
764
|
-
UNLICENSED
|
|
765
588
|
|
|
766
589
|
---
|
|
767
590
|
|
|
768
|
-
|
|
591
|
+
Built By Summit
|
|
769
592
|
|
|
770
|
-
Marker is developed and maintained by
|
|
593
|
+
Marker is developed and maintained by Summit.
|
|
771
594
|
|
|
772
595
|
Creating lightweight developer tools with simple, powerful APIs.
|