@waline/client 3.4.3 → 3.5.1

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/dist/waline.d.ts CHANGED
@@ -302,50 +302,6 @@ interface WalineProps {
302
302
  * @more Setting `'auto'` will display darkmode due to device settings. Filling in CSS selector will enable darkmode only when the selector match waline ancestor nodes.
303
303
  */
304
304
  dark?: string | boolean;
305
- /**
306
- * 设置表情包
307
- *
308
- * Set Emojis
309
- *
310
- * @default ['//unpkg.com/@waline/emojis@1.1.0/weibo']
311
- */
312
- emoji?: (WalineEmojiInfo | WalineEmojiPresets)[] | boolean;
313
- /**
314
- * 设置搜索功能
315
- *
316
- * Customize Search feature
317
- *
318
- * @default true
319
- */
320
- search?: WalineSearchOptions | boolean;
321
- /**
322
- * 代码高亮
323
- *
324
- * Code highlighting
325
- *
326
- * @default true
327
- */
328
- highlighter?: WalineHighlighter | boolean;
329
- /**
330
- * 自定义图片上传方法,方便更好的存储图片
331
- *
332
- * 方法执行时会将图片对象传入。
333
- *
334
- * Custom image upload callback to manage picture by yourself.
335
- *
336
- * We will pass a picture file object when execute it.
337
- *
338
- * @default true
339
- */
340
- imageUploader?: WalineImageUploader | boolean;
341
- /**
342
- * 自定义数学公式处理方法,用于预览。
343
- *
344
- * Custom math formula parse callback for preview.
345
- *
346
- * @default true
347
- */
348
- texRenderer?: WalineTeXRenderer | boolean;
349
305
  /**
350
306
  *
351
307
  * 登录模式状态,可选值:
@@ -364,32 +320,73 @@ interface WalineProps {
364
320
  */
365
321
  login?: WalineLoginStatus;
366
322
  /**
367
- * 是否在页脚展示版权信息
323
+ * 是否在页脚隐藏版权信息
368
324
  *
369
325
  * 为了支持 Waline,我们强烈建议你开启它
370
326
  *
371
- * Whether show copyright in footer
327
+ * Whether hide copyright in footer
372
328
  *
373
329
  * We strongly recommended you to keep it on to support waline
374
330
  *
375
- * @default true
376
331
  */
377
- copyright?: boolean;
332
+ noCopyright?: boolean;
378
333
  /**
334
+ * recaptcha v3 客户端 key
335
+ *
379
336
  * recaptcha v3 client key
380
337
  */
381
338
  recaptchaV3Key?: string;
382
339
  /**
340
+ * turnstile 客户端 key
341
+ *
383
342
  * turnstile client key
384
343
  */
385
344
  turnstileKey?: string;
386
345
  /**
387
- * reaction
346
+ * 文章反应
347
+ *
348
+ * Article reaction
349
+ */
350
+ reaction?: string[];
351
+ /**
352
+ * 设置表情包
353
+ *
354
+ * Set Emojis
355
+ *
356
+ * @default ['//unpkg.com/@waline/emojis@1.1.0/weibo']
388
357
  */
389
- reaction?: string[] | boolean;
358
+ emoji?: (WalineEmojiInfo | WalineEmojiPresets)[];
359
+ /**
360
+ * 设置搜索功能
361
+ *
362
+ * Customize Search feature
363
+ */
364
+ search?: WalineSearchOptions;
365
+ /**
366
+ * 代码块高亮器
367
+ *
368
+ * Code fence highlighter
369
+ */
370
+ highlighter?: WalineHighlighter;
371
+ /**
372
+ * 自定义图片上传方法,方便更好的存储图片
373
+ *
374
+ * 方法执行时会将图片对象传入。
375
+ *
376
+ * Custom image upload callback to manage picture by yourself.
377
+ *
378
+ * We will pass a picture file object when execute it.
379
+ */
380
+ imageUploader?: WalineImageUploader;
381
+ /**
382
+ * 自定义数学公式处理方法,用于预览。
383
+ *
384
+ * Custom math formula parse callback for preview.
385
+ */
386
+ texRenderer?: WalineTeXRenderer;
390
387
  }
391
388
 
392
- interface WalineInitOptions extends Omit<WalineProps, 'path'> {
389
+ interface WalineInitOptions extends Omit<WalineProps, 'path' | 'emoji' | 'search' | 'highlighter' | 'imageUploader' | 'texRenderer'> {
393
390
  /**
394
391
  * Waline 的初始化挂载器。必须是一个**有效的** CSS 选择器 或 HTML 元素
395
392
  *
@@ -401,7 +398,7 @@ interface WalineInitOptions extends Omit<WalineProps, 'path'> {
401
398
  *
402
399
  * Comment number support
403
400
  *
404
- * @default false
401
+ * @default true
405
402
  */
406
403
  comment?: string | boolean;
407
404
  /**
@@ -409,7 +406,7 @@ interface WalineInitOptions extends Omit<WalineProps, 'path'> {
409
406
  *
410
407
  * Pageview number support
411
408
  *
412
- * @default false
409
+ * @default true
413
410
  */
414
411
  pageview?: string | boolean;
415
412
  /**
@@ -424,6 +421,50 @@ interface WalineInitOptions extends Omit<WalineProps, 'path'> {
424
421
  * @default window.location.pathname
425
422
  */
426
423
  path?: string;
424
+ /**
425
+ * 设置表情包
426
+ *
427
+ * Set Emojis
428
+ *
429
+ * @default ['//unpkg.com/@waline/emojis@1.1.0/weibo']
430
+ */
431
+ emoji?: (WalineEmojiInfo | WalineEmojiPresets)[] | boolean;
432
+ /**
433
+ * 设置搜索功能
434
+ *
435
+ * Customize Search feature
436
+ *
437
+ * @default true
438
+ */
439
+ search?: WalineSearchOptions | boolean;
440
+ /**
441
+ * 代码高亮
442
+ *
443
+ * Code highlighting
444
+ *
445
+ * @default true
446
+ */
447
+ highlighter?: WalineHighlighter | boolean;
448
+ /**
449
+ * 自定义图片上传方法,方便更好的存储图片
450
+ *
451
+ * 方法执行时会将图片对象传入。
452
+ *
453
+ * Custom image upload callback to manage picture by yourself.
454
+ *
455
+ * We will pass a picture file object when execute it.
456
+ *
457
+ * @default true
458
+ */
459
+ imageUploader?: WalineImageUploader | boolean;
460
+ /**
461
+ * 自定义数学公式处理方法,用于预览。
462
+ *
463
+ * Custom math formula parse callback for preview.
464
+ *
465
+ * @default true
466
+ */
467
+ texRenderer?: WalineTeXRenderer | boolean;
427
468
  }
428
469
  type WalineAbort = (reason?: any) => void;
429
470