Commit Graph

18 Commits

Author SHA1 Message Date
Emile Bangma
7d148aefc1 fix(callouts)!: match callout DOM to Obsidian (#2104)
* fix(callouts): match callout DOM to Obsidian

* use new transition curve for all callout transitions

* chore!: bump version to 4.5.2
2025-09-21 19:14:03 +02:00
Stephen Tse
bee2fa0fe0 fix(callout): Grid-based callout collapsible animation (#1944)
* Fixed broken nested callout maxHeight calculation

* Implemented grid-based callout collapsible
2025-04-26 11:05:51 -07:00
Emile Bangma
78dec5af34 .callout-content support (#1188)
* .callout-content support

* Use BlockContent | FootnoteContent for callout body

* Update quartz/plugins/transformers/ofm.ts

Co-authored-by: Jacky Zhao <j.zhao2k19@gmail.com>

* Refactor

* Combine child selectors

* Fix multiple callout members

* Empty check

* Replace splice

---------

Co-authored-by: Jacky Zhao <j.zhao2k19@gmail.com>
2024-06-13 16:02:00 -07:00
Jacky Zhao
f34ecf9c45 fix(style): introduce semiBoldWeight and various improvements to reduce CLS 2024-02-17 10:34:51 -08:00
Jacky Zhao
d6549c3a42 fix(style): prevent callout icon from shrinking on long titles (closes #792) 2024-02-02 10:23:24 -08:00
Jacky Zhao
7f3db463fc fix: font weight consistency 2024-02-02 00:53:09 -08:00
LUCASTUCIOUS
d7c2e0b310 feat: Feature/custom callout icon (#727)
* Add icons as masks

To handle a simple way to add custom icons, i made it pure css. Icon are now a mask for the callout-icon div, so they always follow the --color form the current callout.

Now to add a custom icon, you simply add

```css
.callout {
  &[data-callout="custom"] {
    --color: #customcolor;
    --border: #custombordercolor;
    --bg: #custombg;
    --callout-icon: url('data:image/svg+xml; utf8, <custom formatted svg>');

  }
```

to custom.scss

* remove now unused code

* Make callouts an enum

* docs: update instructions for custom callouts

* Prettier & run format

* dynamic matching

For maintainability, make dynamic mathching. If we or Obsidian want to support more callouts, we simply add it to the enum

* callout mapping const

Getting ride of the enum entierly as it's not worth here?

* fix callout icon styling

* Add forgotten icons

* Rebase

* harmonize callout icon and fold icon

* fix docs + prettier

* Update docs/features/callouts.md

Co-authored-by: Jacky Zhao <j.zhao2k19@gmail.com>

* Update quartz/plugins/transformers/ofm.ts

Co-authored-by: Jacky Zhao <j.zhao2k19@gmail.com>

* Suggestions fix

* remove unecessary rules

* comment is always nice

* Update docs/features/callouts.md

---------

Co-authored-by: Jacky Zhao <j.zhao2k19@gmail.com>
2024-01-30 22:10:13 -08:00
LUCASTUCIOUS
9dc0dfde0a feat: Enable custom callout (#724)
* Enable custom callout

make a callout custom defaulted to a note one.

* Add a comment

* remove comment from quartz/plugins/transformers/ofm.ts

Co-authored-by: Jacky Zhao <j.zhao2k19@gmail.com>

* Update quartz/plugins/transformers/ofm.ts

Co-authored-by: Jacky Zhao <j.zhao2k19@gmail.com>

---------

Co-authored-by: Jacky Zhao <j.zhao2k19@gmail.com>
2024-01-24 23:54:24 -08:00
Jacky Zhao
29c4087dea style: fix mulitline callout styling 2023-08-26 10:48:34 -07:00
Jacky Zhao
d256e359b8 fix nested callout folding 2023-08-12 21:16:43 -07:00
Jacky Zhao
fc5c8b4a94 enable rich text in callout title 2023-08-12 10:16:55 -07:00
Jacky Zhao
964e033655 most of creating components, increase legibility of bold in article and callouts 2023-08-07 23:56:50 -07:00
Jacky Zhao
617ea80db1 run prettier 2023-07-22 17:27:41 -07:00
Jacky Zhao
70dcf6acc2 fix default callout state 2023-07-04 18:26:11 -07:00
Jacky Zhao
f078f20c08 basic left,right layout 2023-06-17 14:36:06 -07:00
Jacky Zhao
23624105fb collapsible callout 2023-06-17 13:08:06 -07:00
Jacky Zhao
229f615790 darkmode scripts 2023-06-06 19:48:37 -07:00
Jacky Zhao
69679df121 callouts 2023-06-05 22:14:17 -07:00