You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+45Lines changed: 45 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -436,6 +436,51 @@ Want to add an existing icon pack? Make a pull request with the following:
436
436
437
437
This button will generate a CSS snippet that you can save and use for your custom callout types.
438
438
439
+
## Importing Custom Admonitions
440
+
441
+
Custom admonitions can be imported in settings from a JSON array of definitions.
442
+
443
+
At a _minimum_, you only need a valid admonition type:
444
+
445
+
```json
446
+
[
447
+
{
448
+
"type": "my-custom-type"
449
+
}
450
+
]
451
+
```
452
+
453
+
This will use the `pencil-alt` FontAwesome icon and a random color, and set all other properties as false.
454
+
455
+
However, you can specify an icon and color as well:
456
+
457
+
```json
458
+
[
459
+
{
460
+
"type": "my-custom-type",
461
+
"icon": "globe",
462
+
"color": "120,120,120"
463
+
}
464
+
]
465
+
```
466
+
467
+
If you want to specify an icon pack, you can do so like this:
468
+
469
+
```json
470
+
[
471
+
{
472
+
"type": "my-custom-type",
473
+
"icon": {
474
+
"name": "globe",
475
+
"type": "font-awesome"
476
+
},
477
+
"color": "120,120,120"
478
+
}
479
+
]
480
+
```
481
+
482
+
All of the possible fields are defined [here](https://github.com/valentine195/obsidian-admonition/blob/2fb38ccc0b39ada8d3d0a4476e9ff3333c52c3ae/src/%40types/index.d.ts#L5).
483
+
439
484
## Admonition Settings
440
485
441
486
Settings specific to admonitions are managed in this section.
0 commit comments