├── LICENSE
├── MCL Gallery Cards.css
├── MCL Multi Column.css
├── MCL Wide Views.css
├── README.md
├── Showcases
├── Float with Multi Column Dataview
│ ├── MCL Showcase - Float with Multi Column Dataview.md
│ └── MCL Showcase – Float with Multi Column Dataview.PNG
└── Multi Column Callout and List
│ ├── MCL Showcase - MC Callout and List.md
│ └── MCL Showcase - MC Callout and List.png
├── docs
├── _config.yml
├── _sass
│ └── custom
│ │ ├── custom.scss
│ │ └── setup.scss
├── assets
│ ├── gallery-callout-langkawi.png
│ ├── gallery-cards-settings.png
│ ├── gallery-cssclass-langkawi.png
│ ├── gallery-mermaid-scale.png
│ ├── gc-ss-for-obsd-forum.png
│ ├── hero-gc-float-image.png
│ ├── hero-mc-callout.png
│ ├── hero-mc-list-column-grid-card.png
│ ├── how to install and enable MCL.gif
│ ├── how-to-install-mcl.gif
│ ├── installing-mcl-snippets.mp4
│ ├── installing-mcl-snippets.webm
│ ├── mc-blob-page.png
│ ├── mc-callout-fixed-width.png
│ ├── mc-callout-standard.png
│ ├── mc-callout-width-control.png
│ ├── mc-callout-within-mc-callout.jpg
│ ├── mc-float-callout.png
│ ├── mc-list-card.png
│ ├── mc-list-column.png
│ ├── mc-list-grid.png
│ ├── mc-ss-for-obsd-forum.png
│ ├── multi-column-callout-settings.png
│ ├── multi-column-list-settings.png
│ ├── note.md
│ ├── showcases
│ │ ├── showcase-float-mc-dataview.png
│ │ ├── showcase-mc-callout-and-list-card.png
│ │ ├── showcase-mc-callout-and-list.png
│ │ └── wide-table-example-anp.gif
│ └── wide-views-settings.png
├── gallery-cards
│ ├── 02-image-gallery.md
│ ├── 03-image-control.md
│ ├── 04-image-float.md
│ ├── 05-gc-settings.md
│ ├── index.md
│ └── sync.ffs_db
├── index.md
├── installation.md
├── multi-column
│ ├── 02-multi-column-callout.md
│ ├── 03-float-callout.md
│ ├── 04-blank-callout.md
│ ├── 05-list-column.md
│ ├── 06-list-grid.md
│ ├── 07-list-card.md
│ ├── index.md
│ ├── old-02a-mc-callout-examples.md
│ └── sync.ffs_db
├── showcases
│ ├── float-with-mc-dataview.md
│ ├── index.md
│ ├── mc-callout-and-list.md
│ └── mc-callout-list-card.md
└── wide-views
│ ├── index.md
│ └── wvsettings.md
└── screenshots
├── mcl-callout-example.png
├── mcl-list-example.png
├── mcl-wideviews-example.png
└── multi-column-showcase.png
/LICENSE:
--------------------------------------------------------------------------------
1 | GNU GENERAL PUBLIC LICENSE
2 | Version 3, 29 June 2007
3 |
4 | Copyright (C) 2007 Free Software Foundation, Inc.
5 | Everyone is permitted to copy and distribute verbatim copies
6 | of this license document, but changing it is not allowed.
7 |
8 | Preamble
9 |
10 | The GNU General Public License is a free, copyleft license for
11 | software and other kinds of works.
12 |
13 | The licenses for most software and other practical works are designed
14 | to take away your freedom to share and change the works. By contrast,
15 | the GNU General Public License is intended to guarantee your freedom to
16 | share and change all versions of a program--to make sure it remains free
17 | software for all its users. We, the Free Software Foundation, use the
18 | GNU General Public License for most of our software; it applies also to
19 | any other work released this way by its authors. You can apply it to
20 | your programs, too.
21 |
22 | When we speak of free software, we are referring to freedom, not
23 | price. Our General Public Licenses are designed to make sure that you
24 | have the freedom to distribute copies of free software (and charge for
25 | them if you wish), that you receive source code or can get it if you
26 | want it, that you can change the software or use pieces of it in new
27 | free programs, and that you know you can do these things.
28 |
29 | To protect your rights, we need to prevent others from denying you
30 | these rights or asking you to surrender the rights. Therefore, you have
31 | certain responsibilities if you distribute copies of the software, or if
32 | you modify it: responsibilities to respect the freedom of others.
33 |
34 | For example, if you distribute copies of such a program, whether
35 | gratis or for a fee, you must pass on to the recipients the same
36 | freedoms that you received. You must make sure that they, too, receive
37 | or can get the source code. And you must show them these terms so they
38 | know their rights.
39 |
40 | Developers that use the GNU GPL protect your rights with two steps:
41 | (1) assert copyright on the software, and (2) offer you this License
42 | giving you legal permission to copy, distribute and/or modify it.
43 |
44 | For the developers' and authors' protection, the GPL clearly explains
45 | that there is no warranty for this free software. For both users' and
46 | authors' sake, the GPL requires that modified versions be marked as
47 | changed, so that their problems will not be attributed erroneously to
48 | authors of previous versions.
49 |
50 | Some devices are designed to deny users access to install or run
51 | modified versions of the software inside them, although the manufacturer
52 | can do so. This is fundamentally incompatible with the aim of
53 | protecting users' freedom to change the software. The systematic
54 | pattern of such abuse occurs in the area of products for individuals to
55 | use, which is precisely where it is most unacceptable. Therefore, we
56 | have designed this version of the GPL to prohibit the practice for those
57 | products. If such problems arise substantially in other domains, we
58 | stand ready to extend this provision to those domains in future versions
59 | of the GPL, as needed to protect the freedom of users.
60 |
61 | Finally, every program is threatened constantly by software patents.
62 | States should not allow patents to restrict development and use of
63 | software on general-purpose computers, but in those that do, we wish to
64 | avoid the special danger that patents applied to a free program could
65 | make it effectively proprietary. To prevent this, the GPL assures that
66 | patents cannot be used to render the program non-free.
67 |
68 | The precise terms and conditions for copying, distribution and
69 | modification follow.
70 |
71 | TERMS AND CONDITIONS
72 |
73 | 0. Definitions.
74 |
75 | "This License" refers to version 3 of the GNU General Public License.
76 |
77 | "Copyright" also means copyright-like laws that apply to other kinds of
78 | works, such as semiconductor masks.
79 |
80 | "The Program" refers to any copyrightable work licensed under this
81 | License. Each licensee is addressed as "you". "Licensees" and
82 | "recipients" may be individuals or organizations.
83 |
84 | To "modify" a work means to copy from or adapt all or part of the work
85 | in a fashion requiring copyright permission, other than the making of an
86 | exact copy. The resulting work is called a "modified version" of the
87 | earlier work or a work "based on" the earlier work.
88 |
89 | A "covered work" means either the unmodified Program or a work based
90 | on the Program.
91 |
92 | To "propagate" a work means to do anything with it that, without
93 | permission, would make you directly or secondarily liable for
94 | infringement under applicable copyright law, except executing it on a
95 | computer or modifying a private copy. Propagation includes copying,
96 | distribution (with or without modification), making available to the
97 | public, and in some countries other activities as well.
98 |
99 | To "convey" a work means any kind of propagation that enables other
100 | parties to make or receive copies. Mere interaction with a user through
101 | a computer network, with no transfer of a copy, is not conveying.
102 |
103 | An interactive user interface displays "Appropriate Legal Notices"
104 | to the extent that it includes a convenient and prominently visible
105 | feature that (1) displays an appropriate copyright notice, and (2)
106 | tells the user that there is no warranty for the work (except to the
107 | extent that warranties are provided), that licensees may convey the
108 | work under this License, and how to view a copy of this License. If
109 | the interface presents a list of user commands or options, such as a
110 | menu, a prominent item in the list meets this criterion.
111 |
112 | 1. Source Code.
113 |
114 | The "source code" for a work means the preferred form of the work
115 | for making modifications to it. "Object code" means any non-source
116 | form of a work.
117 |
118 | A "Standard Interface" means an interface that either is an official
119 | standard defined by a recognized standards body, or, in the case of
120 | interfaces specified for a particular programming language, one that
121 | is widely used among developers working in that language.
122 |
123 | The "System Libraries" of an executable work include anything, other
124 | than the work as a whole, that (a) is included in the normal form of
125 | packaging a Major Component, but which is not part of that Major
126 | Component, and (b) serves only to enable use of the work with that
127 | Major Component, or to implement a Standard Interface for which an
128 | implementation is available to the public in source code form. A
129 | "Major Component", in this context, means a major essential component
130 | (kernel, window system, and so on) of the specific operating system
131 | (if any) on which the executable work runs, or a compiler used to
132 | produce the work, or an object code interpreter used to run it.
133 |
134 | The "Corresponding Source" for a work in object code form means all
135 | the source code needed to generate, install, and (for an executable
136 | work) run the object code and to modify the work, including scripts to
137 | control those activities. However, it does not include the work's
138 | System Libraries, or general-purpose tools or generally available free
139 | programs which are used unmodified in performing those activities but
140 | which are not part of the work. For example, Corresponding Source
141 | includes interface definition files associated with source files for
142 | the work, and the source code for shared libraries and dynamically
143 | linked subprograms that the work is specifically designed to require,
144 | such as by intimate data communication or control flow between those
145 | subprograms and other parts of the work.
146 |
147 | The Corresponding Source need not include anything that users
148 | can regenerate automatically from other parts of the Corresponding
149 | Source.
150 |
151 | The Corresponding Source for a work in source code form is that
152 | same work.
153 |
154 | 2. Basic Permissions.
155 |
156 | All rights granted under this License are granted for the term of
157 | copyright on the Program, and are irrevocable provided the stated
158 | conditions are met. This License explicitly affirms your unlimited
159 | permission to run the unmodified Program. The output from running a
160 | covered work is covered by this License only if the output, given its
161 | content, constitutes a covered work. This License acknowledges your
162 | rights of fair use or other equivalent, as provided by copyright law.
163 |
164 | You may make, run and propagate covered works that you do not
165 | convey, without conditions so long as your license otherwise remains
166 | in force. You may convey covered works to others for the sole purpose
167 | of having them make modifications exclusively for you, or provide you
168 | with facilities for running those works, provided that you comply with
169 | the terms of this License in conveying all material for which you do
170 | not control copyright. Those thus making or running the covered works
171 | for you must do so exclusively on your behalf, under your direction
172 | and control, on terms that prohibit them from making any copies of
173 | your copyrighted material outside their relationship with you.
174 |
175 | Conveying under any other circumstances is permitted solely under
176 | the conditions stated below. Sublicensing is not allowed; section 10
177 | makes it unnecessary.
178 |
179 | 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
180 |
181 | No covered work shall be deemed part of an effective technological
182 | measure under any applicable law fulfilling obligations under article
183 | 11 of the WIPO copyright treaty adopted on 20 December 1996, or
184 | similar laws prohibiting or restricting circumvention of such
185 | measures.
186 |
187 | When you convey a covered work, you waive any legal power to forbid
188 | circumvention of technological measures to the extent such circumvention
189 | is effected by exercising rights under this License with respect to
190 | the covered work, and you disclaim any intention to limit operation or
191 | modification of the work as a means of enforcing, against the work's
192 | users, your or third parties' legal rights to forbid circumvention of
193 | technological measures.
194 |
195 | 4. Conveying Verbatim Copies.
196 |
197 | You may convey verbatim copies of the Program's source code as you
198 | receive it, in any medium, provided that you conspicuously and
199 | appropriately publish on each copy an appropriate copyright notice;
200 | keep intact all notices stating that this License and any
201 | non-permissive terms added in accord with section 7 apply to the code;
202 | keep intact all notices of the absence of any warranty; and give all
203 | recipients a copy of this License along with the Program.
204 |
205 | You may charge any price or no price for each copy that you convey,
206 | and you may offer support or warranty protection for a fee.
207 |
208 | 5. Conveying Modified Source Versions.
209 |
210 | You may convey a work based on the Program, or the modifications to
211 | produce it from the Program, in the form of source code under the
212 | terms of section 4, provided that you also meet all of these conditions:
213 |
214 | a) The work must carry prominent notices stating that you modified
215 | it, and giving a relevant date.
216 |
217 | b) The work must carry prominent notices stating that it is
218 | released under this License and any conditions added under section
219 | 7. This requirement modifies the requirement in section 4 to
220 | "keep intact all notices".
221 |
222 | c) You must license the entire work, as a whole, under this
223 | License to anyone who comes into possession of a copy. This
224 | License will therefore apply, along with any applicable section 7
225 | additional terms, to the whole of the work, and all its parts,
226 | regardless of how they are packaged. This License gives no
227 | permission to license the work in any other way, but it does not
228 | invalidate such permission if you have separately received it.
229 |
230 | d) If the work has interactive user interfaces, each must display
231 | Appropriate Legal Notices; however, if the Program has interactive
232 | interfaces that do not display Appropriate Legal Notices, your
233 | work need not make them do so.
234 |
235 | A compilation of a covered work with other separate and independent
236 | works, which are not by their nature extensions of the covered work,
237 | and which are not combined with it such as to form a larger program,
238 | in or on a volume of a storage or distribution medium, is called an
239 | "aggregate" if the compilation and its resulting copyright are not
240 | used to limit the access or legal rights of the compilation's users
241 | beyond what the individual works permit. Inclusion of a covered work
242 | in an aggregate does not cause this License to apply to the other
243 | parts of the aggregate.
244 |
245 | 6. Conveying Non-Source Forms.
246 |
247 | You may convey a covered work in object code form under the terms
248 | of sections 4 and 5, provided that you also convey the
249 | machine-readable Corresponding Source under the terms of this License,
250 | in one of these ways:
251 |
252 | a) Convey the object code in, or embodied in, a physical product
253 | (including a physical distribution medium), accompanied by the
254 | Corresponding Source fixed on a durable physical medium
255 | customarily used for software interchange.
256 |
257 | b) Convey the object code in, or embodied in, a physical product
258 | (including a physical distribution medium), accompanied by a
259 | written offer, valid for at least three years and valid for as
260 | long as you offer spare parts or customer support for that product
261 | model, to give anyone who possesses the object code either (1) a
262 | copy of the Corresponding Source for all the software in the
263 | product that is covered by this License, on a durable physical
264 | medium customarily used for software interchange, for a price no
265 | more than your reasonable cost of physically performing this
266 | conveying of source, or (2) access to copy the
267 | Corresponding Source from a network server at no charge.
268 |
269 | c) Convey individual copies of the object code with a copy of the
270 | written offer to provide the Corresponding Source. This
271 | alternative is allowed only occasionally and noncommercially, and
272 | only if you received the object code with such an offer, in accord
273 | with subsection 6b.
274 |
275 | d) Convey the object code by offering access from a designated
276 | place (gratis or for a charge), and offer equivalent access to the
277 | Corresponding Source in the same way through the same place at no
278 | further charge. You need not require recipients to copy the
279 | Corresponding Source along with the object code. If the place to
280 | copy the object code is a network server, the Corresponding Source
281 | may be on a different server (operated by you or a third party)
282 | that supports equivalent copying facilities, provided you maintain
283 | clear directions next to the object code saying where to find the
284 | Corresponding Source. Regardless of what server hosts the
285 | Corresponding Source, you remain obligated to ensure that it is
286 | available for as long as needed to satisfy these requirements.
287 |
288 | e) Convey the object code using peer-to-peer transmission, provided
289 | you inform other peers where the object code and Corresponding
290 | Source of the work are being offered to the general public at no
291 | charge under subsection 6d.
292 |
293 | A separable portion of the object code, whose source code is excluded
294 | from the Corresponding Source as a System Library, need not be
295 | included in conveying the object code work.
296 |
297 | A "User Product" is either (1) a "consumer product", which means any
298 | tangible personal property which is normally used for personal, family,
299 | or household purposes, or (2) anything designed or sold for incorporation
300 | into a dwelling. In determining whether a product is a consumer product,
301 | doubtful cases shall be resolved in favor of coverage. For a particular
302 | product received by a particular user, "normally used" refers to a
303 | typical or common use of that class of product, regardless of the status
304 | of the particular user or of the way in which the particular user
305 | actually uses, or expects or is expected to use, the product. A product
306 | is a consumer product regardless of whether the product has substantial
307 | commercial, industrial or non-consumer uses, unless such uses represent
308 | the only significant mode of use of the product.
309 |
310 | "Installation Information" for a User Product means any methods,
311 | procedures, authorization keys, or other information required to install
312 | and execute modified versions of a covered work in that User Product from
313 | a modified version of its Corresponding Source. The information must
314 | suffice to ensure that the continued functioning of the modified object
315 | code is in no case prevented or interfered with solely because
316 | modification has been made.
317 |
318 | If you convey an object code work under this section in, or with, or
319 | specifically for use in, a User Product, and the conveying occurs as
320 | part of a transaction in which the right of possession and use of the
321 | User Product is transferred to the recipient in perpetuity or for a
322 | fixed term (regardless of how the transaction is characterized), the
323 | Corresponding Source conveyed under this section must be accompanied
324 | by the Installation Information. But this requirement does not apply
325 | if neither you nor any third party retains the ability to install
326 | modified object code on the User Product (for example, the work has
327 | been installed in ROM).
328 |
329 | The requirement to provide Installation Information does not include a
330 | requirement to continue to provide support service, warranty, or updates
331 | for a work that has been modified or installed by the recipient, or for
332 | the User Product in which it has been modified or installed. Access to a
333 | network may be denied when the modification itself materially and
334 | adversely affects the operation of the network or violates the rules and
335 | protocols for communication across the network.
336 |
337 | Corresponding Source conveyed, and Installation Information provided,
338 | in accord with this section must be in a format that is publicly
339 | documented (and with an implementation available to the public in
340 | source code form), and must require no special password or key for
341 | unpacking, reading or copying.
342 |
343 | 7. Additional Terms.
344 |
345 | "Additional permissions" are terms that supplement the terms of this
346 | License by making exceptions from one or more of its conditions.
347 | Additional permissions that are applicable to the entire Program shall
348 | be treated as though they were included in this License, to the extent
349 | that they are valid under applicable law. If additional permissions
350 | apply only to part of the Program, that part may be used separately
351 | under those permissions, but the entire Program remains governed by
352 | this License without regard to the additional permissions.
353 |
354 | When you convey a copy of a covered work, you may at your option
355 | remove any additional permissions from that copy, or from any part of
356 | it. (Additional permissions may be written to require their own
357 | removal in certain cases when you modify the work.) You may place
358 | additional permissions on material, added by you to a covered work,
359 | for which you have or can give appropriate copyright permission.
360 |
361 | Notwithstanding any other provision of this License, for material you
362 | add to a covered work, you may (if authorized by the copyright holders of
363 | that material) supplement the terms of this License with terms:
364 |
365 | a) Disclaiming warranty or limiting liability differently from the
366 | terms of sections 15 and 16 of this License; or
367 |
368 | b) Requiring preservation of specified reasonable legal notices or
369 | author attributions in that material or in the Appropriate Legal
370 | Notices displayed by works containing it; or
371 |
372 | c) Prohibiting misrepresentation of the origin of that material, or
373 | requiring that modified versions of such material be marked in
374 | reasonable ways as different from the original version; or
375 |
376 | d) Limiting the use for publicity purposes of names of licensors or
377 | authors of the material; or
378 |
379 | e) Declining to grant rights under trademark law for use of some
380 | trade names, trademarks, or service marks; or
381 |
382 | f) Requiring indemnification of licensors and authors of that
383 | material by anyone who conveys the material (or modified versions of
384 | it) with contractual assumptions of liability to the recipient, for
385 | any liability that these contractual assumptions directly impose on
386 | those licensors and authors.
387 |
388 | All other non-permissive additional terms are considered "further
389 | restrictions" within the meaning of section 10. If the Program as you
390 | received it, or any part of it, contains a notice stating that it is
391 | governed by this License along with a term that is a further
392 | restriction, you may remove that term. If a license document contains
393 | a further restriction but permits relicensing or conveying under this
394 | License, you may add to a covered work material governed by the terms
395 | of that license document, provided that the further restriction does
396 | not survive such relicensing or conveying.
397 |
398 | If you add terms to a covered work in accord with this section, you
399 | must place, in the relevant source files, a statement of the
400 | additional terms that apply to those files, or a notice indicating
401 | where to find the applicable terms.
402 |
403 | Additional terms, permissive or non-permissive, may be stated in the
404 | form of a separately written license, or stated as exceptions;
405 | the above requirements apply either way.
406 |
407 | 8. Termination.
408 |
409 | You may not propagate or modify a covered work except as expressly
410 | provided under this License. Any attempt otherwise to propagate or
411 | modify it is void, and will automatically terminate your rights under
412 | this License (including any patent licenses granted under the third
413 | paragraph of section 11).
414 |
415 | However, if you cease all violation of this License, then your
416 | license from a particular copyright holder is reinstated (a)
417 | provisionally, unless and until the copyright holder explicitly and
418 | finally terminates your license, and (b) permanently, if the copyright
419 | holder fails to notify you of the violation by some reasonable means
420 | prior to 60 days after the cessation.
421 |
422 | Moreover, your license from a particular copyright holder is
423 | reinstated permanently if the copyright holder notifies you of the
424 | violation by some reasonable means, this is the first time you have
425 | received notice of violation of this License (for any work) from that
426 | copyright holder, and you cure the violation prior to 30 days after
427 | your receipt of the notice.
428 |
429 | Termination of your rights under this section does not terminate the
430 | licenses of parties who have received copies or rights from you under
431 | this License. If your rights have been terminated and not permanently
432 | reinstated, you do not qualify to receive new licenses for the same
433 | material under section 10.
434 |
435 | 9. Acceptance Not Required for Having Copies.
436 |
437 | You are not required to accept this License in order to receive or
438 | run a copy of the Program. Ancillary propagation of a covered work
439 | occurring solely as a consequence of using peer-to-peer transmission
440 | to receive a copy likewise does not require acceptance. However,
441 | nothing other than this License grants you permission to propagate or
442 | modify any covered work. These actions infringe copyright if you do
443 | not accept this License. Therefore, by modifying or propagating a
444 | covered work, you indicate your acceptance of this License to do so.
445 |
446 | 10. Automatic Licensing of Downstream Recipients.
447 |
448 | Each time you convey a covered work, the recipient automatically
449 | receives a license from the original licensors, to run, modify and
450 | propagate that work, subject to this License. You are not responsible
451 | for enforcing compliance by third parties with this License.
452 |
453 | An "entity transaction" is a transaction transferring control of an
454 | organization, or substantially all assets of one, or subdividing an
455 | organization, or merging organizations. If propagation of a covered
456 | work results from an entity transaction, each party to that
457 | transaction who receives a copy of the work also receives whatever
458 | licenses to the work the party's predecessor in interest had or could
459 | give under the previous paragraph, plus a right to possession of the
460 | Corresponding Source of the work from the predecessor in interest, if
461 | the predecessor has it or can get it with reasonable efforts.
462 |
463 | You may not impose any further restrictions on the exercise of the
464 | rights granted or affirmed under this License. For example, you may
465 | not impose a license fee, royalty, or other charge for exercise of
466 | rights granted under this License, and you may not initiate litigation
467 | (including a cross-claim or counterclaim in a lawsuit) alleging that
468 | any patent claim is infringed by making, using, selling, offering for
469 | sale, or importing the Program or any portion of it.
470 |
471 | 11. Patents.
472 |
473 | A "contributor" is a copyright holder who authorizes use under this
474 | License of the Program or a work on which the Program is based. The
475 | work thus licensed is called the contributor's "contributor version".
476 |
477 | A contributor's "essential patent claims" are all patent claims
478 | owned or controlled by the contributor, whether already acquired or
479 | hereafter acquired, that would be infringed by some manner, permitted
480 | by this License, of making, using, or selling its contributor version,
481 | but do not include claims that would be infringed only as a
482 | consequence of further modification of the contributor version. For
483 | purposes of this definition, "control" includes the right to grant
484 | patent sublicenses in a manner consistent with the requirements of
485 | this License.
486 |
487 | Each contributor grants you a non-exclusive, worldwide, royalty-free
488 | patent license under the contributor's essential patent claims, to
489 | make, use, sell, offer for sale, import and otherwise run, modify and
490 | propagate the contents of its contributor version.
491 |
492 | In the following three paragraphs, a "patent license" is any express
493 | agreement or commitment, however denominated, not to enforce a patent
494 | (such as an express permission to practice a patent or covenant not to
495 | sue for patent infringement). To "grant" such a patent license to a
496 | party means to make such an agreement or commitment not to enforce a
497 | patent against the party.
498 |
499 | If you convey a covered work, knowingly relying on a patent license,
500 | and the Corresponding Source of the work is not available for anyone
501 | to copy, free of charge and under the terms of this License, through a
502 | publicly available network server or other readily accessible means,
503 | then you must either (1) cause the Corresponding Source to be so
504 | available, or (2) arrange to deprive yourself of the benefit of the
505 | patent license for this particular work, or (3) arrange, in a manner
506 | consistent with the requirements of this License, to extend the patent
507 | license to downstream recipients. "Knowingly relying" means you have
508 | actual knowledge that, but for the patent license, your conveying the
509 | covered work in a country, or your recipient's use of the covered work
510 | in a country, would infringe one or more identifiable patents in that
511 | country that you have reason to believe are valid.
512 |
513 | If, pursuant to or in connection with a single transaction or
514 | arrangement, you convey, or propagate by procuring conveyance of, a
515 | covered work, and grant a patent license to some of the parties
516 | receiving the covered work authorizing them to use, propagate, modify
517 | or convey a specific copy of the covered work, then the patent license
518 | you grant is automatically extended to all recipients of the covered
519 | work and works based on it.
520 |
521 | A patent license is "discriminatory" if it does not include within
522 | the scope of its coverage, prohibits the exercise of, or is
523 | conditioned on the non-exercise of one or more of the rights that are
524 | specifically granted under this License. You may not convey a covered
525 | work if you are a party to an arrangement with a third party that is
526 | in the business of distributing software, under which you make payment
527 | to the third party based on the extent of your activity of conveying
528 | the work, and under which the third party grants, to any of the
529 | parties who would receive the covered work from you, a discriminatory
530 | patent license (a) in connection with copies of the covered work
531 | conveyed by you (or copies made from those copies), or (b) primarily
532 | for and in connection with specific products or compilations that
533 | contain the covered work, unless you entered into that arrangement,
534 | or that patent license was granted, prior to 28 March 2007.
535 |
536 | Nothing in this License shall be construed as excluding or limiting
537 | any implied license or other defenses to infringement that may
538 | otherwise be available to you under applicable patent law.
539 |
540 | 12. No Surrender of Others' Freedom.
541 |
542 | If conditions are imposed on you (whether by court order, agreement or
543 | otherwise) that contradict the conditions of this License, they do not
544 | excuse you from the conditions of this License. If you cannot convey a
545 | covered work so as to satisfy simultaneously your obligations under this
546 | License and any other pertinent obligations, then as a consequence you may
547 | not convey it at all. For example, if you agree to terms that obligate you
548 | to collect a royalty for further conveying from those to whom you convey
549 | the Program, the only way you could satisfy both those terms and this
550 | License would be to refrain entirely from conveying the Program.
551 |
552 | 13. Use with the GNU Affero General Public License.
553 |
554 | Notwithstanding any other provision of this License, you have
555 | permission to link or combine any covered work with a work licensed
556 | under version 3 of the GNU Affero General Public License into a single
557 | combined work, and to convey the resulting work. The terms of this
558 | License will continue to apply to the part which is the covered work,
559 | but the special requirements of the GNU Affero General Public License,
560 | section 13, concerning interaction through a network will apply to the
561 | combination as such.
562 |
563 | 14. Revised Versions of this License.
564 |
565 | The Free Software Foundation may publish revised and/or new versions of
566 | the GNU General Public License from time to time. Such new versions will
567 | be similar in spirit to the present version, but may differ in detail to
568 | address new problems or concerns.
569 |
570 | Each version is given a distinguishing version number. If the
571 | Program specifies that a certain numbered version of the GNU General
572 | Public License "or any later version" applies to it, you have the
573 | option of following the terms and conditions either of that numbered
574 | version or of any later version published by the Free Software
575 | Foundation. If the Program does not specify a version number of the
576 | GNU General Public License, you may choose any version ever published
577 | by the Free Software Foundation.
578 |
579 | If the Program specifies that a proxy can decide which future
580 | versions of the GNU General Public License can be used, that proxy's
581 | public statement of acceptance of a version permanently authorizes you
582 | to choose that version for the Program.
583 |
584 | Later license versions may give you additional or different
585 | permissions. However, no additional obligations are imposed on any
586 | author or copyright holder as a result of your choosing to follow a
587 | later version.
588 |
589 | 15. Disclaimer of Warranty.
590 |
591 | THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
592 | APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
593 | HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
594 | OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
595 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
596 | PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
597 | IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
598 | ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
599 |
600 | 16. Limitation of Liability.
601 |
602 | IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
603 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
604 | THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
605 | GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
606 | USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
607 | DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
608 | PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
609 | EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
610 | SUCH DAMAGES.
611 |
612 | 17. Interpretation of Sections 15 and 16.
613 |
614 | If the disclaimer of warranty and limitation of liability provided
615 | above cannot be given local legal effect according to their terms,
616 | reviewing courts shall apply local law that most closely approximates
617 | an absolute waiver of all civil liability in connection with the
618 | Program, unless a warranty or assumption of liability accompanies a
619 | copy of the Program in return for a fee.
620 |
621 | END OF TERMS AND CONDITIONS
622 |
623 | How to Apply These Terms to Your New Programs
624 |
625 | If you develop a new program, and you want it to be of the greatest
626 | possible use to the public, the best way to achieve this is to make it
627 | free software which everyone can redistribute and change under these terms.
628 |
629 | To do so, attach the following notices to the program. It is safest
630 | to attach them to the start of each source file to most effectively
631 | state the exclusion of warranty; and each file should have at least
632 | the "copyright" line and a pointer to where the full notice is found.
633 |
634 |
635 | Copyright (C)
636 |
637 | This program is free software: you can redistribute it and/or modify
638 | it under the terms of the GNU General Public License as published by
639 | the Free Software Foundation, either version 3 of the License, or
640 | (at your option) any later version.
641 |
642 | This program is distributed in the hope that it will be useful,
643 | but WITHOUT ANY WARRANTY; without even the implied warranty of
644 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
645 | GNU General Public License for more details.
646 |
647 | You should have received a copy of the GNU General Public License
648 | along with this program. If not, see .
649 |
650 | Also add information on how to contact you by electronic and paper mail.
651 |
652 | If the program does terminal interaction, make it output a short
653 | notice like this when it starts in an interactive mode:
654 |
655 | Copyright (C)
656 | This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
657 | This is free software, and you are welcome to redistribute it
658 | under certain conditions; type `show c' for details.
659 |
660 | The hypothetical commands `show w' and `show c' should show the appropriate
661 | parts of the General Public License. Of course, your program's commands
662 | might be different; for a GUI interface, you would use an "about box".
663 |
664 | You should also get your employer (if you work as a programmer) or school,
665 | if any, to sign a "copyright disclaimer" for the program, if necessary.
666 | For more information on this, and how to apply and follow the GNU GPL, see
667 | .
668 |
669 | The GNU General Public License does not permit incorporating your program
670 | into proprietary programs. If your program is a subroutine library, you
671 | may consider it more useful to permit linking proprietary applications with
672 | the library. If this is what you want to do, use the GNU Lesser General
673 | Public License instead of this License. But first, please read
674 | .
675 |
--------------------------------------------------------------------------------
/MCL Gallery Cards.css:
--------------------------------------------------------------------------------
1 | /* === README ===
2 | Snippet: MCL Gallery Cards / Author: Faiz Khuzaimah / twitter: @faizkhuzaimah / github: https://github.com/efemkay
3 |
4 | ver 0.9.9 (draft upd 2024-01-14)
5 | - minor performance improvement by reducing image gallery has() scope, focusing on editing view
6 | ver 0.9.8 (updated 2023-11-03)
7 | - re-fixes #50
8 | v0.9.7 (updated 2023-10-13)
9 | - fixes #50 i.e. Gallery Card not working with Minimal due to Minimal max-width specificity
10 | Ver 0.9.5 (updated 2023-07-30)
11 | - fixes on minimal float affecting Minimal own wide table feature
12 | - fixes on properties padding affecting Minimal
13 | - fixes Mermaid zoom in Editing View
14 | Ver 0.9.4 (updated 2023-07-06)
15 | - improve Float Image for editing text in Editing View
16 | - fix for Float Image for Minimal (and respect width settings). No longer require cssClass "minimal-float" but require Style Settings
17 | - improve Image Gallery especially for use in Live Preview without callout
18 | Ver 0.9.2 (updated 2023-05-27)
19 | - fix div width for float image also affecting normal image embed
20 | Ver 0.9.0 (updated 2023-04-01)
21 | - image float
22 | - banner background
23 | - card view for dataview table
24 |
25 | This snippet is part of MCL collection of snippets for customising layout, and it provides the following
26 | - "gallery" callout-metadata i.e. [!|gallery] for flex/grid layout
27 | - use together with MCL Multi Column [!blank-container] for invisible container
28 | - YAML `cssClass: image-gallery` to achieve similar to callout but using only Contextual Typography plugin &
29 | - Image Zoom via css
30 | - Dimension control for images in lists
and Callout === */
52 |
53 | /* Editing and Reading View - Gallery using
and Callout. Using
(in Reading View) to contain and format as gallery view using metadata="gallery" to contain and format as gallery view */
54 | /* Create display: flex and key adjustment on margin and gap */
55 | .image-gallery .markdown-rendered div:has(> p .image-embed) > p,
56 | div[data-callout-metadata*="gallery"].callout > .callout-content > p
57 | { display: flex; gap: var(--callout-gallery-gap); margin-top: calc( var(--callout-gallery-gap) ); margin-bottom: 0; }
58 | .image-gallery .markdown-rendered div:has(> p .image-embed) { margin-top: var(--callout-gallery-gap); }
59 | div[data-callout-metadata*="gallery"].callout > .callout-content { --callout-content-padding: 0.5rem 0 0 0; }
60 | /* Introduce subtle border and make the gallery as object-fit: cover */
61 | .image-gallery .markdown-rendered div:has(> p .image-embed) > p img,
62 | div[data-callout-metadata*="gallery"].callout > .callout-content > p img
63 | { max-height: var(--img-max-height); border: 1px solid var(--background-modifier-border); object-fit: cover; display: block;}
64 | /* display: block for img is important to control the hidden margin-bottom but for Minimal, it uses display: flex for top level divs which pose another "margin" issues no plan to solve yet as this is not critical */
65 |
66 | /* Hack to emulate Reading View masonry in Editing View (for use without callout) - there's no
tag to be container but we can hack to use .cm-line with the help of :has() */
67 | /* improved the css performance */
68 | .image-gallery div.cm-line:not(.HyperMD-list-line):not(.cm-active):has(> .image-embed:not(.cm-callout)) { display: flex; gap: var(--callout-gallery-gap); --img-gallery__buffer-display: none; }
69 | .image-gallery div.cm-line > :is(img.cm-widgetBuffer,span[contenteditable]) { display: var(--img-gallery__buffer-display) !important; }
70 | .image-gallery div:not(.cm-callout):not(.HyperMD-list-line).image-embed img { max-height: calc(var(--img-max-height)/1); display: unset; object-fit: cover; }
71 |
72 |
73 | /* -- Adjustment for Themes -- */
74 |
75 | /* Special Adjustment for Shimmering Focus. Reading View. Overriding max-width */
76 | body:not(.is-mobile) .app-container.app-container .image-gallery p img[src],
77 | body:not(.is-mobile) .app-container.app-container div[data-callout-metadata*="gallery"].callout img[src]
78 | { max-width: 100%; width: unset; margin-block: unset;}
79 |
80 | /* Minimal. Editing View. Left margin. */
81 | .markdown-source-view.mod-cm6 div[data-callout-metadata*="gallery"] .internal-embed.image-embed { margin-left: 0 !important; width: unset;}
82 |
83 | /* Minimal. Editing View. Revert img max width */
84 | body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width .cm-contentContainer.cm-contentContainer>.cm-content>div:has(.image-embed) img { max-width: 100%; }
85 |
86 | /* Minimal. Disable Max Width */
87 | body[class*="minimal-tab-title"] {
88 | &.full-width-media .markdown-preview-view .image-embed img:not(.link-favicon):not(.emoji):not([width]),
89 | &.full-width-media .markdown-preview-view img:not(.link-favicon):not(.emoji):not([width]) {
90 | /* max-width: 100%; */
91 | }
92 | }
93 |
94 | /* -- Adjustment for Plugins -- */
95 |
96 | /* Special Adjustment - for SNW plugin */
97 | .image-gallery div[data-embed-type="image"] > p .snw-embed-preview,
98 | .image-gallery .internal-embed.image-embed ~ .snw-reference.snw-embed,
99 | div[data-callout-metadata*="gallery"].callout > .callout-content > p .snw-embed-preview
100 | { display: var(--gallery-snw-display); width: min-content; height: min-content; }
101 | div[data-callout-metadata*="gallery"].callout > .callout-content > p .internal-embed.image-embed ~ br {display: none;}
102 |
103 |
104 | /* === Images in Lists === */
105 | /* limit the width when in a list (ul only) */
106 | body:not(.list-image-control-off) :is(.HyperMD-list-line,ul) .image-embed.image-embed img:not([width])
107 | { max-height: var(--img-max-height-list); max-width: var(--img-max-width-list); margin-inline: 0; display: unset; object-fit: cover; }
108 |
109 | /* clamping max width to viewport when in mobile. possibly can adopt for desktop as well */
110 | body.is-mobile:not(.list-image-control-off) :is(.HyperMD-list-line,ul) .image-embed.image-embed img:not([width])
111 | { max-width: clamp(calc(var(--img-max-width-list)/2), var(--img-max-width-list), 100%);}
112 |
113 | /*
114 | div:not(.cm-callout).image-embed img { max-height: 200px; max-width: 300px; height: 200px; object-fit: cover;}
115 | */
116 |
117 |
118 | /* === Image Float === */
119 | /* variables */
120 | body {
121 | --float-left-margin: 4px 12px 4px 0;
122 | --float-right-margin: 4px 0 4px 12px;
123 | --float-snw-display: none;
124 | }
125 |
126 | /* float in both Live Preview and Reading View */
127 | img[alt^="left"], img[alt^="float-left"] { float: left; margin: var(--float-left-margin); }
128 | img[alt^="right"], img[alt^="float-right"] { float: right; margin: var(--float-right-margin); }
129 | /* disable box control for parent div to the float */
130 | .internal-embed.image-embed[alt*="float-left"],
131 | .internal-embed.image-embed[alt*="float-right"]
132 | {display: contents; }
133 |
134 | /* provide a float "escape" by allowing user to to add
*/
135 | div.no-float {clear: both; display: inline-grid; height: 1px; width: 100%; background-color: var(--background-secondary);}
136 |
137 | /* remove the br between image and paragraph in Reading View */
138 | p > :is(.image-embed[alt*="left"],.image-embed[alt*="right"]) + br {display: none;}
139 |
140 |
141 | /* -- Adjustment for Plugins */
142 |
143 | /* Breadcrumbs with Minimal. Fix to support plugin */
144 | body[class*="minimal-tab-title"].contextual-typography .minimal-float.markdown-preview-view.markdown-preview-view .BC-trail.markdown-preview-sizer { display: flex; }
145 |
146 | /* SNW plugin */
147 | .internal-embed.image-embed:is([alt="left"],[alt*="|left"],[alt*="left|"],[alt*="float-left"],[alt="right"],[alt*="|right"],[alt*="right|"],[alt*="float-right"]) + .snw-reference.snw-embed { display: var(--float-snw-display); }
148 | .internal-embed.image-embed:is([alt="left"],[alt*="|left"],[alt*="left|"],[alt*="float-left"],[alt="right"],[alt*="|right"],[alt*="right|"],[alt*="float-right"]) + .snw-reference.snw-embed + br { display: none;}
149 |
150 |
151 | /* -- Adjustment for Themes -- */
152 |
153 | /* Blue Topaz. uses body[class*="notebook-liked-markdown-page"] as identifier */
154 | body[class*="notebook-liked-markdown-page"] .view-content .internal-embed.is-loaded img[alt*="left"]:not([class*="emoji"]) { margin: var(--float-left-margin) !important; }
155 | body[class*="notebook-liked-markdown-page"] .view-content .internal-embed.is-loaded img[alt*="right"]:not([class*="emoji"]) { margin: var(--float-right-margin) !important; }
156 |
157 | /* Minimal. Uses body[class*="minimal-tab-title"] as identifier */
158 | body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6 .internal-embed.image-embed[alt*="float"] {width: auto !important; max-width: unset; margin-left: 0 !important;}
159 |
160 | /* Minimal. Minimal Float. (duplicate from Multi Column. Redid "minimal-float" for Minimal V7.0 */
161 | /* minimal own wide table will not work together with float */
162 | /* undo the Minimal "cm-line" sizing */
163 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-contentContainer.cm-contentContainer>.cm-content>div,
164 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-sizer>.embedded-backlinks,
165 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-sizer>.inline-title,
166 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-sizer>.metadata-container
167 | { max-width: none; width: auto; }
168 | /* Re-set the default "cm-sizer" width but respect Minimal Settings */
169 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-sizer { max-width: var(--max-width); width: var(--line-width); }
170 |
171 |
172 | /* to be deleted by 30 Sep 2023 */
173 | /* Duplicate from Multi Column, in case users don't enable that snippet (row 426-437) */
174 | /* Special Adjustment for Minimal theme. Undo the theme flex layout by default. To apply per note basis */
175 | /* .contextual-typography .minimal-float.markdown-preview-view.markdown-preview-view .markdown-preview-sizer { display: unset; } */
176 | /* Special Adjustment for Minimal theme Live Preview float support. Need to revert cm-content width to default theme but cm-embed to auto */
177 | /* body[class*="minimal-tab-title"] .minimal-float:not([class*="wide-"]).markdown-source-view.mod-cm6.is-readable-line-width .cm-contentContainer { width: calc(var(--line-width-adaptive) - var(--folding-offset)); max-width: calc(var(--max-width) - var(--folding-offset)); margin-right: auto; margin-left: max(calc(50% + var(--folding-offset) - var(--line-width-adaptive)/ 2), calc(50% + var(--folding-offset) - var(--max-width)/ 2))!important; } */
178 | /* .minimal-float:not([class*="wide-"]).markdown-source-view.mod-cm6.is-readable-line-width .cm-line { width: auto; max-width: 100%; margin-left: 0 !important; } */
179 | /* .minimal-float:not([class*="wide-"]).markdown-source-view.mod-cm6.is-readable-line-width .cm-embed-block.cm-callout> :is(.callout[data-callout-metadata*="left"], .callout[data-callout-metadata*="right"]) { max-width: 98%; } */
180 | /* .minimal-float:not([class*="wide-"]).markdown-source-view.mod-cm6 .cm-embed-block.cm-callout > .callout { width: auto; } */
181 | /* Special Adjustment for Minimal theme Live Preview float support. Undo margin-left for Image */
182 | /* .minimal-float:not([class*="wide-"]).markdown-source-view.mod-cm6 .cm-embed-block.cm-callout :is(.callout[data-callout-metadata*="left"], .callout[data-callout-metadata*="right"]) .internal-embed.image-embed { margin-left: auto !important; } */
183 |
184 |
185 |
186 | /* === Image Zoom === */
187 | /* must check "Enable Image Zoom via CSS" via Style Settings */
188 |
189 | /* set scale to 100% for images */
190 | .image-zoom .view-content :is(.cm-editor, .markdown-preview-view) img { max-width: 100%; cursor: zoom-in; }
191 |
192 | /* css zoom for images */
193 | body.image-zoom:not(.is-mobile) .view-content :is(.cm-editor,.markdown-preview-view) img:active,
194 | body.image-zoom:not(.is-mobile) .view-content .image-embed:active,
195 | .image-zoom :is(.HyperMD-list-line,ul) .image-embed.image-embed img:active {
196 | cursor: zoom-out; display: block; background: rgba(0,0,0,0.5);
197 | max-height: calc(100% + 1px); max-width: calc(100% - 20px); height: calc(100% + 1px); width: 100%;
198 | object-fit: contain; margin: -0.5px auto 0; padding: 0; text-align: center;
199 | position: fixed; left: 0; right: 0; bottom: 0; z-index: 100;
200 | }
201 |
202 | /* === Mermaid SVG max-width 100% and zoom on click === */
203 | /* for Mermaid SVG zoom, must check "Enable Mermaid Zoom via CSS" via Style Settings */
204 |
205 | /* set scale to 100% for mermaid diagram */
206 | body:not(.mermaid-scale-off) .view-content :is(.cm-editor, .markdown-preview-view) .mermaid svg { max-width: 100%; height: 100%}
207 | body.mermaid-scale-off .mermaid { overflow-x: auto; }
208 |
209 | .mermaid-zoom .view-content .mermaid svg { cursor: zoom-in; }
210 |
211 | /* css zoom for mermaid diagram */
212 | body.mermaid-zoom:not(.is-mobile) .view-content .markdown-reading-view .mermaid svg:active {
213 | cursor: zoom-out; display: block; object-fit:contain; margin: -0.5px auto 0; padding: 0;
214 | max-height: calc(100% + 1px); max-width: calc(100% - 20px); height: calc(100% + 1px); width: 100%;
215 | text-align: center; z-index: 100; position: fixed; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.8);
216 | }
217 | /* editing view */
218 | body.mermaid-zoom:not(.is-mobile) .markdown-source-view .cm-embed-block:has(.mermaid svg:active) {
219 | text-align: center;
220 | top: 0; left: 0; right: 0; bottom: 0;
221 | z-index: 100;
222 | position: fixed;
223 | background: rgba(0,0,0,0.8)
224 | }
225 | body.mermaid-zoom:not(.is-mobile) .markdown-source-view. .cm-embed-block:has(.mermaid svg:active) .mermaid { overflow-x: hidden; }
226 | body.mermaid-zoom:not(.is-mobile) .markdown-source-view .mermaid svg:active {
227 | cursor: zoom-out;
228 | position: fixed;
229 | width: 100%; height: 100%;
230 | top: 0; left: 0;
231 | }
232 |
233 |
234 | /* === Dataview related ===*/
235 |
236 | /* Change Dataview table into card view
237 | - no style settings option yet
238 | */
239 |
240 | body {
241 | --bg-color-dv-card: var(--background-modifier-backlinks);
242 | --border-color-dv-card: var(--background-modifier-border);
243 | }
244 | .dv-card table.dataview { position: relative; display: flex; flex-direction: column; font-size: 0.9em; }
245 |
246 | /* convert the thead */
247 | .dv-card table.dataview thead { display: flex; flex-flow: row-reverse; border-radius: var(--size-4-2); position: relative; padding-bottom: 0.4em; }
248 | .dv-card table.dataview thead tr { margin: 0; }
249 | .dv-card:is(*,.markdown-source-view.mod-cm6) table.dataview.table-view-table thead th { padding-left: 0; padding: 0.2em 1.3em 0 0.3em; border-width: 0; font-size: 0.9rem; color: var(--text-faint); font-family: var(--h3-font);}
250 |
251 | /* convert the tbody into card like structure */
252 | .dv-card table.dataview tbody { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); grid-gap: var(--size-4-2); }
253 | .dv-card table.dataview tbody tr { background-color: var(--bg-color-dv-card); display: flex; flex-direction: column; border: 1px solid var(--border-color-dv-card); border-radius: var(--size-4-2); margin-top: 0; margin-bottom: 0; }
254 | .dv-card table.dataview tbody tr:hover { background-color: var(--background-secondary) !important; }
255 | .dv-card table.dataview tbody td { display: flex; padding-block: 0; }
256 | .dv-card table.dataview tbody td:first-child { font-weight: var(--bold-weight); }
257 | .dv-card table.dataview tbody td:not(:first-child) { color: var(--text-muted); font-size: 0.9em; }
258 | .dv-card table.dataview tbody td:last-child { padding-bottom: 0.5em; }
259 | .dv-card table.dataview tbody td:not(:last-child):not(:first-child)>.el-p:not(.el-embed-image) { border-bottom: 1px solid var(--border-color-dv-card); width: 100%; }
260 | .dv-card table.dataview tbody td > * { padding-block: 0.5em; }
261 | .dv-card table.dataview tbody td > ul { padding-block: 0.2em; }
262 |
263 | /* Remove the li indent and other cosmetics */
264 | .dv-card table.dataview :is(ul,ol) { padding-inline-start: 0; margin-block: 0 !important; }
265 | .dv-card table.dataview li:not(:last-of-type).dataview-result-list-li {border-bottom: 1px dashed DarkSlateGray;}
266 | .dv-card table.dataview li.dataview-result-list-li::marker { color: transparent; }
267 |
268 | /* Special Adjustment for Stardust's Table Enhancer plugin */
269 | table.dataview .table-height-adjust th, .table-height-adjust tr { height: revert !important; }
270 |
271 | /* Special Adjustment for Listive theme */
272 | .dv-card .table-view-table li:not(.cards li.dataview-result-list-li) {margin-left: revert; }
273 |
274 | /* Special Adjustment for thead background for most themes */
275 | .dv-card thead :is(tr, th.table-view-th) {background-color: transparent;}
276 | .dv-card thead :is(tr, th) {border-width: 0;}
277 |
278 |
279 |
280 | /*=== MCL Banner ===*/
281 | /* banner using css only -- https://forum.obsidian.md/t/css-how-to-style-the-first-image-in-a-note/52839/ */
282 |
283 | body {
284 | --mcl-banner-height-normal: 200px;
285 | --mcl-banner-height-tall: 300px;
286 | --mcl-banner-overlap-title-adj: 0px;
287 | --mcl-banner-no-title-adj: 0px;
288 | }
289 | body:not(.show-inline-title) .markdown-reading-view {
290 | --mcl-banner-no-title-adj: 25px; /* reading view bigger to adjust for minor overlap */
291 | }
292 | body:not(.show-inline-title) .markdown-source-view {
293 | --mcl-banner-no-title-adj: 15px;
294 | }
295 |
296 |
297 | /* make the div (in LP) containing the image doesn't control the css box-sizing */
298 | .markdown-source-view .cm-line:has(> .internal-embed.image-embed > img[alt*="mcl-banner"]),
299 | .markdown-source-view :is(.internal-embed.image-embed, .cm-line):has(> img[alt*="mcl-banner"]) { display: contents; }
300 |
301 | /* original forum post snippet with minor tweak */
302 | img[alt*="mcl-banner"] {
303 | position: absolute;
304 | top: 0; left: 0;
305 | height: var(--mcl-banner-height-normal); width: 100%;
306 | margin-right: auto; margin-left: auto;
307 | object-fit: cover; object-position: 50% 50%;
308 | overflow: hidden;
309 | user-select: none;
310 | /* z-index: -1; */
311 | }
312 |
313 | img[alt*="mcl-banner"][alt*="gradient"] {
314 | -webkit-mask-image: -webkit-gradient(linear, left top, left bottom, color-stop(80%, rgba(0,0,0,1)), color-stop(100%, rgba(0,0,0,0)) );
315 | mask-image: linear-gradient(to bottom, rgba(0,0,0,1), rgba(0,0,0,0));
316 | }
317 |
318 | /* padding to distance text content from banner V1 *//*
319 | .view-content:has(img[alt*="mcl-banner"]) .inline-title
320 | { position: relative; padding-top: calc(var(--mcl-banner-height-normal) - 50px + var(--mcl-banner-overlap-title-adj) + var(--mcl-banner-no-title-adj)); z-index: 30; }
321 | .view-content:has(img[alt*="mcl-banner"][alt*="-tall"]) :is(.cm-content > div:first-child, .mod-header)
322 | { padding-top: calc(var(--mcl-banner-height-tall) - 50px + var(--mcl-banner-overlap-title-adj) + var(--mcl-banner-no-title-adj) ); }
323 |
324 | /* padding to distance text content from banner V2 */
325 | .view-content:has(img[alt*="mcl-banner"]) :is(.cm-sizer, .markdown-preview-section)
326 | { padding-top: calc(var(--mcl-banner-height-normal) - 50px + var(--mcl-banner-overlap-title-adj) + var(--mcl-banner-no-title-adj)); }
327 | .view-content:has(img[alt*="mcl-banner"][alt*="-tall"]) :is(.cm-sizer, .markdown-preview-section)
328 | { padding-top: calc(var(--mcl-banner-height-tall) - 50px + var(--mcl-banner-overlap-title-adj) + var(--mcl-banner-no-title-adj) ); }
329 | .view-content:has(img[alt*="mcl-banner"]) .inline-title
330 | { position: relative; z-index: 30; }
331 |
332 |
333 |
334 | /* add option to adjust vertical position by adding the alt metadata "higher" or "lower" */
335 | img[alt*="mcl-banner"][alt*="y-30"] { object-position: 50% 20%; }
336 | img[alt*="mcl-banner"][alt*="y-20"] { object-position: 50% 30%; }
337 | img[alt*="mcl-banner"][alt*="y-10"] { object-position: 50% 40%; }
338 | img[alt*="mcl-banner"][alt*="y+10"] { object-position: 50% 60%; }
339 | img[alt*="mcl-banner"][alt*="y+20"] { object-position: 50% 70%; }
340 | img[alt*="mcl-banner"][alt*="y+30"] { object-position: 50% 80%; }
341 |
342 | /* tall adjustment */
343 | img[alt*="mcl-banner"][alt*="-tall"] { height: var(--mcl-banner-height-tall); }
344 |
345 |
346 | /* minor tweak for me, since i have snippet to make image has rounded corner */
347 | img[alt*="mcl-banner"] { border-radius: revert; }
348 | /* minor tweak for me, to hide snw block reference counter for the banner */
349 | .internal-embed.media-embed.image-embed.is-loaded + .snw-reference.snw-embed {display: none;}
350 |
351 |
352 | /* === Image Aspect Ratio === */
353 | /* Apply to any images using either hashtag after image url or image alt-text */
354 | .internal-embed.image-embed[src*="1-1"] > img,
355 | img[src*="1-1"],
356 | img[alt*="1-1"]
357 | { aspect-ratio: 1/1; object-fit: cover; }
358 | .internal-embed.image-embed[src*="4-3"] > img,
359 | img[src*="4-3"],
360 | img[alt*="4-3"]
361 | { aspect-ratio: 4/3; object-fit: cover; }
362 | .internal-embed.image-embed[src*="16-9"] > img,
363 | img[src*="16-9"],
364 | img[alt*="16-9"]
365 | { aspect-ratio: 16/9; object-fit: cover; }
366 |
367 |
368 | /* === Image Caption === */
369 | /* This will only works with local images, web images cannot be supported
370 | mainly because obsidian doesn't render a parent div for the image.
371 | Local images with md link still works. */
372 | :is(.markdown-source-view.mod-cm6, .markdown-reading-view) .internal-embed.image-embed[src*="caption"] { display: inline-block; width: fit-content; }
373 | .image-embed[src*="caption"]::after { content: attr(alt); display: block; text-align: center; font-style: italic; }
374 |
375 |
376 | /* === ALPHA VERSION testing Timeline in lists === */
377 | /*
378 | .tag-mcltimeline > ul > li > *:not(ul) { text-align: center; align-self: baseline; }
379 | .tag-mcltimeline > ul > li {
380 | display: grid;
381 | grid-template-columns: 0 3fr 7fr;
382 | grid-template-rows: auto;
383 | grid-template-areas:
384 | "indicator timeline details"
385 | "indicator . details";
386 | grid-column-gap: 1em;
387 |
388 | }
389 | .tag-mcltimeline > ul > li > ul { grid-area: details; text-align: left; }
390 | .tag-mcltimeline > ul > li > .collapse-indicator { grid-area: indicator; }
391 | .tag-mcltimeline > ul ul { margin-left: 0.5em; }
392 | */
393 |
394 |
395 |
396 |
397 | /* @settings
398 |
399 | name: Modular CSS Layout - Gallery Cards
400 | id: modular-css-layout-gc
401 | settings:
402 |
403 | -
404 | id: gc-general-title
405 | title: General Image Settings
406 | type: heading
407 | level: 2
408 | collapsed: true
409 | -
410 | id: image-zoom
411 | title: Enable Image Zoom via CSS
412 | type: class-toggle
413 | -
414 | id: img-border-radius
415 | title: Image Border Radius (any unit, no space)
416 | type: variable-text
417 | default: 15px
418 |
419 |
420 | -
421 | id: gc-callout-title
422 | title: Image Gallery Settings
423 | description: For image gallery using `gallery` callout-metadata and `image-gallery` YAML
424 | type: heading
425 | level: 2
426 | collapsed: true
427 | -
428 | id: gallery-snw-display
429 | title: Hide Strange New World Indicators in Image Gallery
430 | type: variable-select
431 | default: none
432 | options:
433 | -
434 | label: Show
435 | value: inline-block
436 | -
437 | label: Hide
438 | value: none
439 | -
440 | id: callout-gallery-gap
441 | title: Gallery Callout Gap (any unit, no space)
442 | type: variable-text
443 | default: 5px
444 | -
445 | id: img-max-height
446 | title: Max Height for Images (any unit, no space)
447 | type: variable-text
448 | default: 300px
449 | -
450 | id: img-max-width
451 | title: Max Width for Images (any unit, no space)
452 | type: variable-text
453 | default: 350px
454 |
455 |
456 |
457 | -
458 | id: gc-float-title
459 | title: Image Float / Aside
460 | type: heading
461 | level: 2
462 | collapsed: true
463 | -
464 | id: float-left-margin
465 | title: Margin for Image Float Right (any unit, no space)
466 | description: Enter in following order - "top right bottom left"
467 | type: variable-text
468 | default: 4px 12px 4px 0px
469 | -
470 | id: float-right-margin
471 | title: Margin for Image Float Right (any unit, no space)
472 | description: Enter in following order - "top right bottom left"
473 | type: variable-text
474 | default: 4px 0px 4px 12px
475 | -
476 | id: float-snw-display
477 | title: Hide SNW indicator in Image Float / Aside
478 | type: variable-select
479 | default: none
480 | options:
481 | -
482 | label: Show
483 | value: inline-block
484 | -
485 | label: Hide
486 | value: none
487 |
488 |
489 |
490 | -
491 | id: gc-list-title
492 | title: Image in List Settings
493 | type: heading
494 | level: 2
495 | collapsed: true
496 | -
497 | id: list-image-control-off
498 | title: Disable Control for Image in List
499 | description: Disabling will revert image dimension to Obsidian default behaviour
500 | type: class-toggle
501 | -
502 | id: img-max-height-list
503 | title: Max Height for Images (any unit, no space)
504 | type: variable-text
505 | default: 270px
506 | -
507 | id: img-max-width-list
508 | title: Max Width for Images (any unit, no space)
509 | type: variable-text
510 | default: 300px
511 |
512 | -
513 | id: gc-mermaid-title
514 | title: Mermaid SVG Settings
515 | type: heading
516 | level: 2
517 | collapsed: true
518 | -
519 | id: mermaid-scale-off
520 | title: Disable scaling for Mermaid diagram
521 | description: Disabling will revert Mermaid diagram dimension to Obsidian default behaviour
522 | type: class-toggle
523 | -
524 | id: mermaid-zoom
525 | title: Enable Image Zoom via CSS
526 | type: class-toggle
527 | */
528 |
--------------------------------------------------------------------------------
/MCL Multi Column.css:
--------------------------------------------------------------------------------
1 | /* === README ===
2 | Snippet: MCL Multi Column / Author: Faiz Khuzaimah / twitter: @faizkhuzaimah / github: https://github.com/efemkay
3 |
4 | Ver 0.10.0 (updated 2024-09-01)
5 | - introduce fw dw and pw
6 | - added left-right margin for Float Callout
7 | - refactor List Column code to improve performance
8 | Ver 0.9.10 (updated 2024-06-26)
9 | - fix issues #81 and #89
10 | Ver 0.9.9 (updated 2024-01-25)
11 | - code cleanup (including -small -medium -large)
12 | - improve css performance on float but require cssclass use again
13 | Ver 0.9.8 (updated 2023-11-03)
14 | - fixes on sub-callout becomes flexible height (and introduce option for such)
15 | Ver 0.9.7 (updated 2023-10-13)
16 | - GH FR issue #41, #42 and fixed GH issue #35. MC Callout now supports sub-blockquote and sub-paragraph
17 | - GH FR issue #43. MC Callout now supports Multi Column within Multi Column
18 | Ver 0.9.5 (updated 2023-07-30)
19 | - fixes on minimal float affecting Minimal own wide table feature
20 | - fixes on properties padding affecting Minimal
21 | Ver 0.9.4 (updated 2023-07-06)
22 | - improved MC Callout compatibility with Minimal theme V7.0
23 | - improved MC Callout compatibility with Blue Topaz
24 | Ver 0.9.3 (updated 2023-06-24)
25 | - add support for List Column for li that's also a header
26 | - fixes on column ruler to apply properly only for List Column on first ul only
27 | - fixes on Float Callout in LP not floating due to additional div layer
28 | Ver 0.9.2 (updated 2023-05-27)
29 | - fix MC List Card mistakenly affect non List Card bullet list padding in same note
30 | - fix obsidian default bullet "draw" not rendered properly in List Column (for the ones using tag and contextual typography plugin)
31 | Ver 0.9.1 (updated 2023-04-06)
32 | - fix MC "fixed center" option not properly coded
33 | - fix MC List Grid previous not support sublist
34 | - fix MC List Column margin top for first column
35 | - fix MC List Grid for first bullet header
36 | Ver 0.9.0 (updated 2023-04-01)
37 | - MC - add option to hide SNW block ref for images in MC Callout
38 | - MC - added wide option for List Grid/Card
39 | - MC - added option to adjust float callout top margin
40 | - MC - added fixed width option
41 | - fix support minimal Callout style Outlined
42 | - List Column/Grid/Card fully support :has()
43 |
44 | What is this snippet for?
45 | - to allow Obsidian users to change the layout with preset css by just specifying
46 | the cssClass in the frontmatter (YAML) or naming the Callout block
47 | - available cssClass
48 | - cssClass: two-column-list
49 | - cssClass: {.two-column-list-block}
50 | - cssClass: three-column-list
51 | - cssClass: {.three-column-list-block}
52 | - cssClass: multi-column-list
53 | - available Callout format
54 | - [!multi-column]
55 | - [!blank] / [!blank-container]
56 |
57 | Compatibility
58 | - tested to work fine with the following Community Theme
59 | - Default Theme
60 | - Big Sur / Blue Topaz / California Cost / Notation / Pisum / Prism / Things / Typewriter (with minor issue on title color)
61 | - known to be not working
62 | - Primary (due to the theme heaving theming, box-shadow and so on)
63 |
64 | Credits
65 | - Kevin Powell Youtube channel
66 | - https://css-tricks.com/
67 | - discord OMG members @Cáo thoát tục (Cáo thoát tục#6993), @mulfok (mulfok#6931) and @Rainbell (Rainbell#3617)
68 | - kepano for accomodating my snippets adjustment
69 | - trainbuffer for numerous help and assisted css snippets
70 | */
71 |
72 |
73 |
74 | body{
75 | /* for list column, grid and card */
76 | --list-min-width: 200px;
77 | --col-rule-color: var(--background-modifier-border); /* #b3b3b3; */
78 | --col-rule-width: 1px;
79 | --list-grid-min-width: 250px;
80 | --list-grid-wide-min-width: 350px;
81 |
82 | }
83 | .theme-dark {
84 | /* --background-mcl-card: hsl(300, 5%, 15%); */
85 | }
86 | .theme-light {
87 | /* --background-mcl-card: hsl(300, 5%, 90%); */
88 | }
89 |
90 |
91 | /* === General === */
92 |
93 | /* -- Fixed Width definition -- */
94 | /* quadruple the last .callout to win specificity with main multi-column callout */
95 | div[data-callout-metadata*="fw"].callout.callout.callout { flex-grow: 0; flex-shrink: 0;}
96 | div[data-callout-metadata*="fw1"].callout.callout.callout.callout { flex-basis: 100px; width: 100px; }
97 | div[data-callout-metadata*="fw2"].callout.callout.callout.callout { flex-basis: 200px; width: 200px; }
98 | div[data-callout-metadata*="fw3"].callout.callout.callout.callout { flex-basis: 300px; width: 300px; }
99 | div[data-callout-metadata*="fw4"].callout.callout.callout.callout { flex-basis: 400px; width: 400px; }
100 | div[data-callout-metadata*="fw5"].callout.callout.callout.callout { flex-basis: 500px; width: 500px; }
101 | div[data-callout-metadata*="fw6"].callout.callout.callout.callout { flex-basis: 600px; width: 600px; }
102 | div[data-callout-metadata*="fw7"].callout.callout.callout.callout { flex-basis: 700px; width: 700px; }
103 | div[data-callout-metadata*="fw8"].callout.callout.callout.callout { flex-basis: 800px; width: 800px; }
104 | div[data-callout-metadata*="fw9"].callout.callout.callout.callout { flex-basis: 900px; width: 900px; }
105 |
106 | div[data-callout-metadata*="pw1"].callout.callout.callout.callout { flex-basis: 10%; width: 10%; }
107 | div[data-callout-metadata*="pw2"].callout.callout.callout.callout { flex-basis: 18%; width: 18%; }
108 | div[data-callout-metadata*="pw3"].callout.callout.callout.callout { flex-basis: 28%; width: 28%; }
109 | div[data-callout-metadata*="pw4"].callout.callout.callout.callout { flex-basis: 38%; width: 38%; }
110 | div[data-callout-metadata*="pw5"].callout.callout.callout.callout { flex-basis: 48%; width: 48%; }
111 | div[data-callout-metadata*="pw6"].callout.callout.callout.callout { flex-basis: 58%; width: 58%; }
112 | div[data-callout-metadata*="pw7"].callout.callout.callout.callout { flex-basis: 68%; width: 68%; }
113 | div[data-callout-metadata*="pw8"].callout.callout.callout.callout { flex-basis: 78%; width: 78%; }
114 | div[data-callout-metadata*="pw9"].callout.callout.callout.callout { flex-basis: 88%; width: 88%; }
115 |
116 |
117 | /* metadata "wide-x" to control subcallout flexible max width. only discrete 2,4,8,16 */
118 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="mw0"].callout.callout { flex-basis: 0; }
119 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw1"].callout { flex: 1 0 auto; }
120 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw2"].callout { flex: 2 0 auto; }
121 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw3"].callout { flex: 3 0 auto; }
122 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw4"].callout { flex: 4 0 auto; }
123 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw5"].callout { flex: 5 0 auto; }
124 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw6"].callout { flex: 6 0 auto; }
125 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw7"].callout { flex: 7 0 auto; }
126 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw8"].callout { flex: 8 0 auto; }
127 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="dw9"].callout { flex: 9 0 auto; }
128 |
129 |
130 |
131 |
132 | /* === Multi Column Callout (MCC) === */
133 | /* some issues still persists
134 | (2) some theme uses transparency to affect .callout-title */
135 |
136 | /* common MCC variables */
137 | body {
138 | --mcc-img-snw-display: none;
139 | --callout-min-width: 200px;
140 | --callout-nowrap-min-width: 250px;
141 | --callout-gap: 1em;
142 | --callout-margin: 0px;
143 | }
144 | [data-callout="multi-column"].callout {
145 | --callout-blend-mode: normal;
146 | }
147 |
148 | /* -- Main MCC Code -- */
149 |
150 | /* remove callout-title and make callout-content as part of main callout for box formatting */
151 | div[data-callout="multi-column"].callout > .callout-title { display: none; }
152 | div[data-callout="multi-column"].callout > .callout-content { display: contents; }
153 | /* make the main callout a flex and remove box formatting */
154 | /* --columns: unset to undo Sanctum's mod */
155 | div[data-callout="multi-column"].callout
156 | { display: flex; flex-wrap: wrap; gap: var(--callout-gap); background: unset; border: unset; margin: unset; padding: unset; clear: both; --columns: unset; }
157 | /* make the subcallout in flex column to allow growing vertically */
158 | div[data-callout="multi-column"].callout .callout:not([data-callout="multi-column"]) { display: flex; flex-direction: column; }
159 | div[data-callout="multi-column"].callout:not(.is-collapsed) .callout { margin-inline: var(--callout-margin); margin-block: var(--callout-margin); } /* to allow spacing for box shadow */
160 | div[data-callout="multi-column"].callout .callout .callout-content { flex-grow: 1}
161 |
162 | div[data-callout="multi-column"].callout > .callout-content > *:is(div,ul,blockquote,p) { flex: 1 1 var(--callout-min-width); margin: 0;}
163 |
164 | /* metadata "wide-x" to control subcallout flexible max width. only discrete 2,4,8,16 */
165 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="min-0"] { flex-basis: 0; }
166 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="wide-2"] { flex-grow: 2; }
167 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="wide-3"] { flex-grow: 3; }
168 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="wide-4"] { flex-grow: 4; }
169 | div[data-callout="multi-column"].callout > .callout-content > div[data-callout-metadata*="wide-5"] { flex-grow: 5; }
170 |
171 | @media (min-width: 500px) {
172 | /* .is-collapsed is used to draw the border-left only when it's collapsed */
173 | div[data-callout="multi-column"].callout > div.callout-content .callout.is-collapsed { box-shadow: unset; height: min-content;}
174 | }
175 |
176 | /* -- MCC Variant - Flexible Height for Subcallout / Children -- */
177 | /* also useful if one wants to have non callout children like table and don't want to fill the height */
178 | div[data-callout="multi-column"].callout {}
179 | div[data-callout="multi-column"][data-callout-metadata*="flex-h"].callout { align-items: flex-start; }
180 |
181 | /* -- MCC Variation - Fixed Columns -- */
182 | div[data-callout="multi-column"][data-callout-metadata*="col3"]:not([data-callout-metadata*="icons"]).callout {
183 | display: grid;
184 | grid-template-columns: 1fr 1fr 1fr;
185 | }
186 |
187 | /* -- MCC Variation - Icons -- */
188 |
189 | /* Main code */
190 | div[data-callout="multi-column"][data-callout-metadata*="icons"] {
191 |
192 | &.callout { justify-content: center; }
193 | &.callout .callout { display: flex; flex-direction: row; flex-wrap: wrap; }
194 | &.callout.callout .callout-content > p { flex-grow: 1; text-align: center; }
195 | /* Options for number of columns */
196 | &[data-callout-metadata*="col2"].callout.callout .callout-content > p { flex-basis: 40%; }
197 | &[data-callout-metadata*="col3"].callout.callout .callout-content > p { flex-basis: 30%; }
198 | &[data-callout-metadata*="col4"].callout.callout .callout-content > p { flex-basis: 22%; }
199 | &[data-callout-metadata*="col5"].callout.callout .callout-content > p { flex-basis: 18%; }
200 |
201 | /* listive theme */
202 | &.callout p:first-child { margin-top: revert; }
203 | }
204 |
205 |
206 | /* -- MCC Variation - Fixed Width Option -- */
207 | /* Fixed Width Option (using callout-metadata) */
208 | div[data-callout="multi-column"][data-callout-metadata*="center-fixed"].callout { justify-content: center; }
209 | div[data-callout="multi-column"][data-callout-metadata*="left-fixed"].callout { justify-content: flex-start; }
210 | div[data-callout="multi-column"][data-callout-metadata*="right-fixed"].callout { justify-content: flex-end; }
211 | div[data-callout="multi-column"][data-callout-metadata*="fixed"].callout > .callout-content > *:is(div,ul) { flex-grow: 0; }
212 |
213 | /* Callout size for Fixed Width Option */
214 | div[data-callout="multi-column"][data-callout-metadata*="fixed"][data-callout-metadata*="small"].callout > .callout-content > *:is(div,ul) { flex-basis: calc( var(--float-small-width) * 0.5 ); }
215 | div[data-callout="multi-column"][data-callout-metadata*="fixed"][data-callout-metadata*="medium"].callout > .callout-content > *:is(div,ul) { flex-basis: calc( var(--float-medium-width) * 0.65); }
216 | div[data-callout="multi-column"][data-callout-metadata*="fixed"][data-callout-metadata*="large"].callout > .callout-content > *:is(div,ul) { flex-basis: calc( var(--float-large-width) * 0.8); }
217 |
218 |
219 | /* -- MCC Variation - No Wrap Option -- */
220 |
221 | /* No-Wrap Option (using callout-metadata) - for single row with horizontal scrollbar */
222 | div[data-callout="multi-column"][data-callout-metadata*="no-wrap"].callout {
223 | flex-wrap: nowrap; overflow-x: scroll;
224 | & > .callout-content > *:is(div,ul) { flex-shrink: 0; }
225 | }
226 |
227 | /* No-Wrap Option, Width Options. Legacy width option. better to dw, pw and fw options at the top */
228 | .callout[data-callout="multi-column"][data-callout-metadata*="no-wrap"] .callout[data-callout-metadata*="small"] { flex-basis: 300px; }
229 | .callout[data-callout="multi-column"][data-callout-metadata*="no-wrap"] .callout[data-callout-metadata*="medium"] { flex-basis: 400px; }
230 | .callout[data-callout="multi-column"][data-callout-metadata*="no-wrap"] .callout[data-callout-metadata*="large"] { flex-basis: 600px; }
231 |
232 | /* Align center for items in callout */
233 | div[data-callout="multi-column"] .callout[data-callout-metadata*="center"] { text-align: center; }
234 |
235 |
236 | /* -- Special Adjustment for Community Themes -- */
237 |
238 | /* Special Adjustment -- for theme with negative margin & box shadow. (e.g. Prism) */
239 | div[data-callout="multi-column"].callout > .callout-content { margin-top: unset;}
240 | div[data-callout="multi-column"].callout:not(.is-collapsed) { box-shadow: unset;}
241 |
242 | /* Blue Topaz - remove box shadow from main [!multi-column] */
243 | body[class*="notebook-liked-markdown-page"].shade-callout-style .callout[data-callout="multi-column"] { box-shadow: unset !important; }
244 |
245 | /* Special Adjustment -- for minimal left margin *//*
246 | .markdown-source-view.mod-cm6.is-readable-line-width .cm-embed-block.cm-callout > div[data-callout="multi-column"].callout
247 | { width: 100%; max-width: 100%; margin-inline: 0 !important; }
248 |
249 | /* Minimal - .dataview.list-view-ul width - Minimal set the width with --line-width-adaptive (40rem by default) */
250 | body:not(.table-100):not(.table-max):not(.table-wide) .markdown-preview-view.is-readable-line-width:not(.table-100):not(.table-max):not(.table-wide) div[data-callout="multi-column"].callout .dataview.list-view-ul {width: auto;}
251 |
252 | /* Minimal -- Callout Outline, to ensure sub-callout not overlapped and hidden */
253 | .callouts-outlined div[data-callout="multi-column"].callout:not(.is-collapsed) .callout:not([data-callout="multi-column"]) {
254 | margin-top: 1em;
255 | }
256 |
257 |
258 | /* -- Special Adjustment for Plugins / Markdown Elements -- */
259 |
260 | /* SNW plugin */
261 | div[data-callout*="multi-column"].callout .callout-content span.image-embed + .snw-reference { display: var(--mcc-img-snw-display); }
262 |
263 |
264 |
265 |
266 | /* === Blank Container "DIV"'s - can be used with Main Multi-Column layout above === */
267 |
268 | /* "blank-container" - no bg, no border, no title, no nothing, and remove the ligthen effect */
269 | div[data-callout*="blank"].callout {--callout-blend-mode: normal;}
270 | div[data-callout*="blank"].callout > .callout-title { display: none; }
271 | div[data-callout*="blank"].callout > .callout-content {display: contents;}
272 | div[data-callout*="blank"].callout { border: 0; padding-top: 0; padding-inline: 5px; background: unset; box-shadow: unset; }
273 |
274 | /* -- No Margin -- */
275 | /* issues still persists
276 | - headers font size not same
277 | - "no-margin" not fully workable in editing view due to wide-page override for Minimal theme
278 | */
279 | div[data-callout-metadata*="no-margin"]:is(.cm-callout, .callout.callout, .callout.callout .callout-content) {margin: 0; padding: 0;}
280 |
281 | /* -- No Margin for only child -- */
282 | div[data-callout*="blank"].callout .callout-content > p:only-child {
283 | margin-block: 0;
284 | }
285 |
286 |
287 | /* -- Special Adjustment for Themes -- */
288 |
289 | /* Mado. Remove theme's pseudo left border */
290 | div[data-callout*="blank"] .callout-content::before { display: none; }
291 |
292 |
293 | /* === Text Justify === */
294 |
295 | .text-justify :is(.markdown-preview-view p,.markdown-source-view .cm-line) { text-align: justify; }
296 |
297 |
298 | /* === Floating Callout - Base === */
299 | /* float uses callout-metadata to control the layout. can apply to any callout */
300 |
301 | /* variables */
302 | body {
303 | --float-small-width: 300px;
304 | --float-medium-width: 400px;
305 | --float-large-width: 600px;
306 |
307 | --float-left-callout-margin: 0 15px 0 0;
308 | --float-right-callout-margin: 0 0 0 15px;
309 | --float-callout-top-margin: 0em;
310 | --float-callout-bottom-margin: 0em;
311 | --float-callout-snw-display: none;
312 | }
313 | /* variables */
314 | body {
315 | --float-left-callout-margin-inline: 0 12px;
316 | --float-right-callout-margin-inline: 12px 0;
317 | --float-snw-display: none;
318 | }
319 |
320 |
321 | /* -- Main Code. Use media query so that floats only works when there's enough width */
322 | @media (min-width: 500px){
323 | .markdown-source-view .cm-embed-block.cm-callout:has(> div.markdown-rendered > [data-callout-metadata*="float-left"]) { display: inline; z-index: 30;}
324 | .markdown-source-view .cm-embed-block.cm-callout:has(> div.markdown-rendered > [data-callout-metadata*="float-left"]) > div > .callout { float: left; z-index: 30; }
325 | .markdown-source-view .cm-embed-block.cm-callout:has(> div.markdown-rendered > [data-callout-metadata*="float-left"]) > .edit-block-button { display: none; }
326 | .markdown-reading-view div[data-callout-metadata*="left"].callout {float: left;}
327 |
328 | .markdown-source-view .cm-embed-block.cm-callout:has(> div.markdown-rendered > [data-callout-metadata*="float-right"]) { display: inline; z-index: 30;}
329 | .markdown-source-view .cm-embed-block.cm-callout:has(> div.markdown-rendered > [data-callout-metadata*="float-right"]) > div > .callout { float: right; z-index: 30; }
330 | .markdown-source-view .cm-embed-block.cm-callout:has(> div.markdown-rendered > [data-callout-metadata*="float-right"]) > .edit-block-button { display: none; }
331 | .markdown-reading-view div[data-callout-metadata*="right"].callout {float: right; }
332 |
333 | .markdown-source-view.mod-cm6 .cm-embed-block.cm-callout :is(.callout[data-callout-metadata*="left"], .callout[data-callout-metadata*="right"]) .callout-content > p:last-of-type { margin-bottom: auto;}
334 |
335 | [data-callout-metadata*="float-right"].cm-embed-block.cm-callout {width: auto !important;}
336 |
337 | /* remove margin from first para in the float callout */
338 | .callout:is(div[data-callout-metadata*="left"],div[data-callout-metadata*="right"]) .callout-content > :is(p:first-child,ul:first-child,ol:first-child) {margin-top: 0;}
339 |
340 | /* Adjustable Gap */
341 | /* 26Mar2023 only top for now, to work on left-right later */
342 | .markdown-source-view.mod-cm6 .callout:is(div[data-callout-metadata*="left"]),
343 | .markdown-source-view.mod-cm6 .callout:is(div[data-callout-metadata*="right"])
344 | { margin-top: calc(1em * var(--line-height-normal) + var(--float-callout-top-margin)); }
345 |
346 | /**/
347 | .markdown-source-view.mod-cm6 .callout:is(div[data-callout-metadata*="left"]),
348 | .markdown-reading-view div[data-callout-metadata*="left"].callout {
349 | margin-inline: var(--float-left-callout-margin-inline);
350 | }
351 | .markdown-source-view.mod-cm6 .callout:is(div[data-callout-metadata*="right"]),
352 | .markdown-reading-view div[data-callout-metadata*="right"].callout {
353 | margin-inline: var(--float-right-callout-margin-inline);
354 | }
355 | }
356 |
357 | /* -- FC Size Options -- */
358 |
359 | /* legacy width option. better to dw, pw and fw options at the top */
360 | [data-callout-metadata*="-small"].callout {width: var(--float-small-width);}
361 | [data-callout-metadata*="-medium"].callout {width: var(--float-medium-width);}
362 | [data-callout-metadata*="-large"].callout {width: var(--float-large-width);}
363 |
364 |
365 | /* -- Special Adjustment for Plugins / Markdown Elements -- */
366 |
367 | /* Option for Caption */
368 | div:is([data-callout-metadata*="caption"]).callout > .callout-content > p .image-embed[alt]:not([alt$=".png"], [alt$=".jpg"], [alt$=".jpeg"], [alt$=".tiff"])::after {content: attr(alt); text-align: center; display: block; font-style: italic; color: var(--text-muted); }
369 | div:is([data-callout-metadata*="caption"]).callout > .callout-content > p img:not(.emoji) { display: block; margin-right: auto; margin-left: auto;}
370 |
371 | /* Introduce clear to break the float */
372 | /* .markdown-preview-view h2, *//* remove this as it has weird spacing effect */
373 | .embedded-backlinks { clear: both; }
374 |
375 | /* for Blockquote underlap the float layout -- to remove by 30Jun2024, no longer needed */
376 | /* .markdown-preview-view :is(blockquote) { overflow-x: auto; } /* fix for blockquote underlap */
377 | /* .markdown-preview-view :is(p) { overflow: unset; } /* fix for para not wrapping around float. applicable for Willemstad */
378 |
379 | /* for SNW plugin */
380 | div:is([data-callout-metadata*="caption"],[data-callout-metadata*="left"],[data-callout-metadata*="right"]).callout > .callout-content > p .snw-embed-preview { display: var(--float-callout-snw-display); width: min-content; height: min-content; }
381 | div:is([data-callout-metadata*="caption"],[data-callout-metadata*="left"],[data-callout-metadata*="right"]).callout > .callout-content > p .internal-embed.image-embed ~ br {display: none;}
382 |
383 |
384 | /* -- Special Adjustment for Themes -- */
385 |
386 | /* Minimal. Minimal Float. Updated for Minimal V7.4.7 */
387 | /* "Reset" the default "cm-sizer" width but respect Minimal Settings, and require cssclass ".minimal-float" as Minimal own wide table will not work together with float i.e. removing :not(:has(table)) from .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)) */
388 | .minimal-float.markdown-source-view.mod-cm6 {
389 | .cm-sizer {
390 | max-width: var(--max-width); width: var(--line-width);
391 | }
392 | .cm-contentContainer.cm-contentContainer > .cm-content > div,
393 | .cm-sizer > .embedded-backlinks,
394 | .cm-sizer > .inline-title,
395 | .cm-sizer > .metadata-container {
396 | max-width: none; width: auto;
397 | }
398 | }
399 |
400 | /* Minimal. Previous Minimal Float but with performance issue. Kept for reference until 30 June 2024 */ /*
401 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-sizer { max-width: var(--max-width); width: var(--line-width); }
402 |
403 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-contentContainer.cm-contentContainer>.cm-content>div,
404 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-sizer>.embedded-backlinks,
405 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-sizer>.inline-title,
406 | :is(body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width:not(:has(table)), .minimal-float.markdown-source-view.mod-cm6) .cm-sizer>.metadata-container
407 | { max-width: none; width: auto; }
408 |
409 |
410 | /* Minimal - fix to support Breadcrumbs plugin. Sub to the above LP float fix for Minimal */
411 | body[class*="minimal-tab-title"].contextual-typography .minimal-float.markdown-preview-view.markdown-preview-view .BC-trail.markdown-preview-sizer { display: flex; }
412 |
413 | /* Minimal - Size Option fix due to !important */
414 | /* Minimal. Uses body[class*="minimal-tab-title"] as identifier. To override (have higher specificity) the width param. Can be merged to main code later on */
415 | @media (min-width: 500px){
416 | body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width .cm-embed-block.cm-callout > div[data-callout-metadata$="small"].callout { width: var(--float-small-width) !important; margin-left: 0 !important; }
417 | body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width .cm-embed-block.cm-callout > div[data-callout-metadata$="medium"].callout { width: var(--float-medium-width) !important; margin-left: 0 !important; }
418 | }
419 | @media (min-width: 750px){
420 | body[class*="minimal-tab-title"] .markdown-source-view.mod-cm6.is-readable-line-width .cm-embed-block.cm-callout > div[data-callout-metadata$="large"].callout { width: var(--float-large-width); margin-left: 0 !important; }
421 | }
422 |
423 |
424 | /* === List Column ===*/
425 | /* supported for (1) css :has(), (2) yaml cssclass, (3) CT plugin, and (4) MA plugin
426 | - CSS :has() can be applied to sublists, so no column rule. CT plugin apply to div that houses the ul, so column gap is different
427 | - xx-column-list for first level only list, but apply anywhere but xx-column-list-block apply at block level. Both require JV's Markdown Attributes plugin
428 | */
429 |
430 |
431 | /* -- List Column/Grid/Card general styling -- */
432 |
433 | /* hide tag in rendered view, dim it in edit mode and small size */
434 | :is(div[class*="mcl"].markdown-rendered, .markdown-rendered) a[href*="#mcl"] {display: none;}
435 | /* :is(div[class*="mcl"].markdown-rendered, .markdown-rendered div[class*="mcl"]) a[href*="#mcl"] {display: none;} */
436 | .cm-s-obsidian .HyperMD-list-line span[class*="mcl"] {background-color: var(--background-primary) !important; color: var(--text-faint); font-size: 0.9rem; }
437 |
438 |
439 | /* -- List Column using YAML cssclass and Markdown Attributes i.e. {.three-column-list-block} -- */
440 |
441 | /* define the column gap and column rule */
442 | .two-column-list div > ul, .two-column-list-block,
443 | .three-column-list div > ul, .three-column-list-block,
444 | .four-column-list div > ul, .four-column-list-block,
445 | .multi-column-list div > ul, .multi-column-list-block
446 | { column-gap: 3rem; column-rule: var(--col-rule-width) solid var(--col-rule-color); }
447 |
448 | /* define the column count, for fixed number of columns, to subject it to note's width (in future can use @container when installer v1.2.7 widely used ) */
449 | @media (min-width: 500px ){
450 | .two-column-list div > ul, .two-column-list-block {columns: 2; }
451 | .three-column-list div > ul, .three-column-list-block {columns: 3; }
452 | .four-column-list div > ul, .four-column-list-block {columns: 4; }
453 | }
454 | .multi-column-list div > ul, .multi-column-list-block { column-width: var(--list-min-width); }
455 |
456 | /* Special adjustment for footnotes applied with -colum-list-block -- obsidian creates a tag at the last
*/
457 | .footnotes [class$="-column-list-block"] li:last-of-type br:last-of-type {display: none;}
458 |
459 |
460 | /* -- List Column Using Tag (using CSS has) -- */
461 |
462 | /* set the column rules at ul level and adjust the margin */
463 | ul:has(> li > [data-heading] > [href*="#mcl/list-column"]),
464 | ul:has(> li > [href*="#mcl/list-column"]) {
465 | margin-top: 0;
466 | column-width: var(--list-min-width); column-gap: 1rem;
467 | column-rule: var(--col-rule-width) solid var(--col-rule-color);
468 | }
469 |
470 | /* give some margin for the div, for first ul only */
471 | div:has(> ul > li > [href*="#mcl/list-column"]),
472 | div:has(> ul > li > [data-heading] > [href*="#mcl/list-column"])
473 | { margin-top: 0.8em; }
474 |
475 | /* readjust [!blank] display contents */
476 | div[data-callout*="blank"] > .callout-content:has(li [href*="#mcl/list-column"]) {display: block; margin: 0; padding: 0; }
477 |
478 |
479 | /* -- General Adjustment for List Column -- */
480 |
481 | /* Adjustment for misaligned bullets (this is a hack, need to find better solution later) */
482 | ul:has([href="#mcl/list-column"]) li > .list-bullet::after, /* :has() */
483 | .markdown-preview-view[class*="column-list"] li > .list-bullet::after, /* yaml cssclass */
484 | .tag-mcllist-column ul li > .list-bullet::after, /* contextual typography */
485 | ul[class*="column-list"] li > .list-bullet::after /* markdown attributes */
486 | { position: relative; }
487 |
488 |
489 | /* -- Special Adjustment for Plugins for List Column -- */
490 |
491 | /* for Custom Classes */
492 | div.cc-container:has(li > [href="#mcl/list-column"]) { width: 100%; }
493 |
494 |
495 |
496 | /* === List Grid (using hashtag) === */
497 | /* supported (1) :has() and (2) Contextual Typography plugin */
498 |
499 | /* -- Main Code -- */
500 |
501 | ul:has(> li > [data-heading] > [href*="#mcl/list-grid"]),
502 | ul:has(> li > [href*="#mcl/list-grid"]),
503 | div[class*="mcllist-grid"] ul:first-child
504 | { display: grid; grid-template-columns: repeat(auto-fit,minmax(var(--list-grid-min-width),1fr)); }
505 |
506 | ul:has(> li > [data-heading] > [href*="#mcl/list-grid-wide"]),
507 | ul:has(> li > [href*="#mcl/list-grid-wide"]),
508 | div[class*="mcllist-grid-wide"] ul:first-child
509 | { grid-template-columns: repeat(auto-fit,minmax(var(--list-grid-wide-min-width),1fr)); }
510 |
511 | ul:has(> li > [data-heading] > [href*="#mcl/list-grid"]) > li:not(:last-of-type),
512 | ul:has(> li > [href*="#mcl/list-grid"]) > li:not(:last-of-type),
513 | div[class*="mcllist-grid"] ul:first-child > li:not(:last-of-type)
514 | { padding-right: 1.6em; }
515 |
516 | ul:has(> li > [data-heading] > [href*="#mcl/list-grid-sm"]),
517 | ul:has(> li > [href*="#mcl/list-grid-sm"]),
518 | div[class*="mcllist-grid-sm"] ul:first-child
519 | { --list-grid-min-width: 20%; }
520 |
521 |
522 | /* - dashboard style, page level only, apply to any first level */
523 | /* -- applicable only when width > 400pt, else just single column */
524 | /* grid list block level cannot be done, it breaks formatting */
525 | @media (min-width: 500px) {
526 | .two-column-grid-list div > ul { display: grid; grid-column-gap:3em; grid-template-columns:repeat(2,1fr);}
527 | }
528 | @media (min-width: 600px) {
529 | .three-column-grid-list div > ul { display: grid; grid-column-gap:3em; grid-template-columns:repeat(3,1fr);}
530 | }
531 |
532 |
533 |
534 | /* === List Card (using hashtag) === */
535 | /* supported (1) :has() and (2) Contextual Typography plugin */
536 |
537 | body {
538 | --mcl-card-header-border-width: 1px;
539 | --mcl-card-bg-color: var(--background-secondary);
540 | --mcl-card-gap: 0.2em;
541 | --mcl-card-border-width: 1px;
542 | --mcl-card-border-color: var(--background-modifier-border);
543 | }
544 |
545 | /* -- Main Code -- */
546 |
547 | /* make the list grid, remove some ul padding */
548 |
549 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), [class*="mcllist-card"]) ul:first-child { display: grid; grid-template-columns: repeat(auto-fit,minmax(var(--list-grid-min-width),1fr)); margin-block-start: 0.5em; }
550 | :is(div:has(> ul [data-heading*="#mcl/list-card-wide"]), [class*="mcllist-card-wide"]) ul:first-child { grid-template-columns: repeat(auto-fit, minmax(var(--list-grid-wide-min-width),1fr));}
551 | /* unindent first level bullet */
552 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) ul ul:not(ul ul ul) { padding-left: 0.1em; } /* with v1.6 this is somewhat redundant */
553 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) ul ul:not(ul ul ul) > li { margin-inline-start: 0; }
554 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), div:has(> ul [data-heading*="#mcl/list-card"]) .callout-content, .tag-mcllist-card, .tag-mcllist-card .callout-content) > ul { padding-left: 0; }
555 | :is(.is-mobile .markdown-preview-section) :is(div:has([data-heading*="#mcl/list-card"]), .tag-mcllist-card) :is(ol:not(ol ol ol), ul:not(ul ul ul)) {padding-left: 0;}
556 | /* reposition the collapse indicator and hover behaviour */
557 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), div:has(> ul [data-heading*="#mcl/list-card"]) .callout-content, .tag-mcllist-card, .tag-mcllist-card .callout-content) > ul > li {position: relative;}
558 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), div:has(> ul [data-heading*="#mcl/list-card"]) .callout-content, .tag-mcllist-card, .tag-mcllist-card .callout-content) > ul > li:hover > .collapse-indicator,
559 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), div:has(> ul [data-heading*="#mcl/list-card"]) .callout-content, .tag-mcllist-card, .tag-mcllist-card .callout-content) > ul > li > ul > li:hover > .collapse-indicator {opacity: 1;}
560 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), div:has(> ul [data-heading*="#mcl/list-card"]) .callout-content, .tag-mcllist-card, .tag-mcllist-card .callout-content) > ul > li > .collapse-indicator,
561 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), div:has(> ul [data-heading*="#mcl/list-card"]) .callout-content, .tag-mcllist-card, .tag-mcllist-card .callout-content) > ul > li > ul > li > .collapse-indicator {position: absolute; right: 0.7em; padding-right: 0;}
562 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) ul::before {display: none;}
563 | /* decorate the first heading for cards */
564 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [data-heading*="#mcl/list-card"]) .callout-content, .tag-mcllist-card, .tag-mcllist-card .callout-content) > ul > li:not(.is-collapsed) > [data-heading] {border-bottom: var(--mcl-card-header-border-width) solid var(--mcl-card-border-color); margin-bottom: 0.2em;}
565 | /* hide the list bullet for list-card for first and second level */
566 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) > div > div > ul > li > .list-bullet::after,
567 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) > div > div > ul > li > ul > li > .list-bullet::after,
568 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) > ul > li::before,
569 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) > ul > li > ul > li::before,
570 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) > ul > li > .list-bullet::after,
571 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) > ul > li > ul > li > .list-bullet::after {visibility: hidden;}
572 | /* remove the indentation guide */
573 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) ul:not(ul ul ul ul)::before {--indentation-guide-width: 0;}
574 | .markdown-rendered.show-indentation-guide :is(div:has(> ul [data-heading*="#mcl/list-card"]), .tag-mcllist-card) li > ul::before,
575 | .markdown-rendered.show-indentation-guide :is(div:has(> ul [data-heading*="#mcl/list-card"]), .tag-mcllist-card) li > ol::before {border-right: 0; border-left: 0; }
576 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) li {list-style: none;}
577 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) li li li {list-style: circle;}
578 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) .callout ul:not(ul ul) > li,
579 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) ul:not(ul ul) > li
580 | { margin-inline: var(--mcl-card-gap); margin-bottom: calc(var(--mcl-card-gap)*2); padding: 0.3em 0.5em; outline: var(--mcl-card-border-width) solid var(--mcl-card-border-color); border-radius: 0.5em; background-color: var(--mcl-card-bg-color);}
581 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) ul:not(ul ul) > li img {width: 100%;}
582 | :is(div:has(> ul [data-heading*="#mcl/list-card"]), div:has(> ul [href*="#mcl/list-card"]), .tag-mcllist-card) ul img {margin: 0; float: none;}
583 |
584 |
585 | /* -- Special Adjustment for Themes -- */
586 |
587 | /* Sanctum */
588 | .markdown-rendered .tag-mcllist-card ul img[alt*=right] {margin: 0;}
589 |
590 |
591 |
592 | /* === Style Settings === */
593 |
594 | /* @settings
595 |
596 | name: Modular CSS Layout - Multi Column
597 | id: modular-css-layout-mc
598 | settings:
599 |
600 | -
601 | id: multi-column-title
602 | title: Multi Column Callout Settings
603 | type: heading
604 | level: 1
605 | collapsed: true
606 |
607 | -
608 | id: mc-callout-general-title
609 | title: MCC -- General
610 | type: heading
611 | level: 2
612 | collapsed: false
613 | -
614 | id: mcc-img-snw-display
615 | title: Hide SNW indicator for images in MC Callout
616 | type: variable-select
617 | default: none
618 | options:
619 | -
620 | label: Show
621 | value: inline
622 | -
623 | label: Hide
624 | value: none
625 |
626 | -
627 | id: mc-callout-width-title
628 | title: MCC -- Width
629 | type: heading
630 | level: 2
631 | collapsed: false
632 | -
633 | id: callout-min-width
634 | title: Minimum Sub-Callout Width
635 | description: for sub-callout in [!multi-column]. in px units
636 | type: variable-number-slider
637 | default: 200
638 | min: 100
639 | max: 500
640 | step: 50
641 | format: px
642 | -
643 | id: callout-nowrap-min-width
644 | title: Minimum NO-WRAP Sub-Callout Width
645 | description: for sub-callout in [!multi-column|no-wrap]. in px units
646 | type: variable-number-slider
647 | default: 250
648 | min: 100
649 | max: 500
650 | step: 50
651 | format: px
652 |
653 | -
654 | id: mc-callout-gap-title
655 | title: MCC -- Gap & Margin
656 | type: heading
657 | level: 2
658 | collapsed: false
659 | -
660 | id: callout-gap
661 | title: Sub-Callout Gap (any unit)
662 | description: NO spacing between figure and unit
663 | type: variable-text
664 | default: 1em
665 | -
666 | id: callout-margin
667 | title: Sub-Callout Margin (any unit)
668 | description: to allow some spacing for box-shadow
669 | type: variable-text
670 | default: 0px
671 |
672 |
673 |
674 | -
675 | id: float-callout-title
676 | title: Float Callout Settings
677 | type: heading
678 | level: 1
679 | collapsed: true
680 |
681 | -
682 | id: float-callout-general-title
683 | title: FC -- General
684 | type: heading
685 | level: 2
686 | collapsed: false
687 |
688 | -
689 | id: float-callout-snw-display
690 | title: Hide SNW indicator in Callout Float / Aside
691 | type: variable-select
692 | default: none
693 | options:
694 | -
695 | label: Show
696 | value: inline-block
697 | -
698 | label: Hide
699 | value: none
700 |
701 | -
702 | id: float-width-title
703 | title: FC -- Width
704 | type: heading
705 | level: 2
706 | collapsed: false
707 | -
708 | id: float-small-width
709 | title: Floating Callout Width - Small (in px)
710 | type: variable-number-slider
711 | default: 300
712 | min: 200
713 | max: 450
714 | step: 50
715 | format: px
716 | -
717 | id: float-medium-width
718 | title: Floating Callout Width - Medium (in px)
719 | type: variable-number-slider
720 | default: 400
721 | min: 300
722 | max: 550
723 | step: 50
724 | format: px
725 | -
726 | id: float-large-width
727 | title: Floating Callout Width - Large (in px)
728 | type: variable-number-slider
729 | default: 600
730 | min: 500
731 | max: 750
732 | step: 50
733 | format: px
734 |
735 | -
736 | id: float-gap-title
737 | title: FC -- Gap & Margin
738 | type: heading
739 | level: 2
740 | collapsed: false
741 | -
742 | id: float-callout-top-margin
743 | title: Adjust top margin for Float Left and Float Right
744 | description: Can use em or px unit
745 | type: variable-text
746 | default: 0em
747 | -
748 | id: float-left-callout-margin-inline
749 | title: Adjust left-right margin for Float Left Callout
750 | description: Enter in this order - "left right". Can use em or px unit
751 | type: variable-text
752 | default: 0px 12px
753 | -
754 | id: float-right-callout-margin-inline
755 | title: Adjust left-right margin for Float Right Callout
756 | description: Enter in this order - "left right". Can use em or px unit
757 | type: variable-text
758 | default: 12px 0px
759 |
760 |
761 |
762 | -
763 | id: mc-list-column-title
764 | title: List Column
765 | description: using `{.xxx-column-list-xxx}` and `#mcl/list-column`
766 | type: heading
767 | level: 1
768 | collapsed: true
769 | -
770 | id: list-column-width-title
771 | title: Width control for List Column
772 | type: heading
773 | level: 2
774 | collapsed: false
775 | -
776 | id: list-min-width
777 | title: Minimum Column Width (in px)
778 | type: variable-number-slider
779 | default: 200
780 | min: 100
781 | max: 500
782 | step: 50
783 | format: px
784 |
785 | -
786 | id: list-column-deco-title
787 | title: Decoratives control for List Column
788 | type: heading
789 | level: 2
790 | collapsed: false
791 | -
792 | id: col-rule-width
793 | title: Ruler (vertical line between columns) width for List Column
794 | description: in px unit. Set to 0 to disable ruler
795 | type: variable-number-slider
796 | default: 1
797 | min: 0
798 | max: 4
799 | step: 1
800 | format: px
801 | -
802 | id: col-rule-color
803 | title: Ruler (vertical line between columns) color for List Column
804 | type: variable-themed-color
805 | format: hsl
806 | opacity: true
807 | default-light: '#'
808 | default-dark: '#'
809 |
810 |
811 | -
812 | id: mc-list-grid-title
813 | title: List Grid and List Card
814 | description: using `#mcl/list-grid` and `#mcl/list-card`
815 | type: heading
816 | level: 1
817 | collapsed: true
818 |
819 | -
820 | id: list-grid-card-width-title
821 | title: Width control for List Grid and List Card
822 | type: heading
823 | level: 2
824 | collapsed: false
825 | -
826 | id: list-grid-min-width
827 | title: Minimum width for normal List Grid/Card
828 | description: For `#mcl-list-grid` or `#mcl-list-card`. Can use em or px unit
829 | type: variable-text
830 | default: 250px
831 | -
832 | id: list-grid-wide-min-width
833 | title: Minimum width for Wide List Grid/Card
834 | description: For `#mcl/list-grid-wide` or `#mcl/list-card-wide`. Can use em or px unit
835 | type: variable-text
836 | default: 350px
837 |
838 | -
839 | id: list-card-deco-title
840 | title: Decoratives control for List Card
841 | type: heading
842 | level: 2
843 | collapsed: false
844 | -
845 | id: mcl-card-header-border-width
846 | title: Bottom border for first header in List Card
847 | description: Can use em or px unit. Set to 0 to disable the border
848 | type: variable-text
849 | default: 1px
850 | -
851 | id: mcl-card-bg-color
852 | title: Background color for List Card
853 | type: variable-themed-color
854 | format: hsl
855 | opacity: true
856 | default-light: '#'
857 | default-dark: '#'
858 | -
859 | id: mcl-card-gap
860 | title: Gap between cards for List Card
861 | description: Can use em or px unit
862 | type: variable-text
863 | default: 0.2em
864 | -
865 | id: mcl-card-border-width
866 | title: Border width for each card in List Card
867 | description: Can use em or px unit. Set to 0 to disable the border
868 | type: variable-text
869 | default: 1px
870 | -
871 | id: mcl-card-border-color
872 | title: Border color for each card in List Card
873 | type: variable-themed-color
874 | format: hsl
875 | opacity: true
876 | default-light: '#'
877 | default-dark: '#'
878 |
879 | */
880 |
--------------------------------------------------------------------------------
/MCL Wide Views.css:
--------------------------------------------------------------------------------
1 | /* === README for MCL Wide Views snippet / Author: Faiz Khuzaimah / twitter: @faizkhuzaimah / github: https://github.com/efemkay
2 | Ver 0.9.6 (updated 2023-09-09) - Code refactor to make use predefined variables and more efficient code base
3 | - refactor all wide views features. require Obsidian installer v1.1.9.
4 | - fixed all issues from previous codebase
5 | Version 0.9.4 (updated 2023-07-05)
6 | - fixed wide-backlinks not working since Obsidian V1
7 | - improved support for Minimal V7
8 |
9 | What is this snippet for?
10 | - for any users to use with any theme to complement any missing page/block width control
11 | - available cssClass:
12 | - wide-page
13 | - wide-table
14 | - wide-dataview
15 | - wide-callout
16 | - wide-backlinks
17 | - narrow-page
18 | - style settings toggle
19 | - is-adj-rll with adj-rll-max-width input
20 |
21 | Important Notice
22 | - this snippet requires Obsidian installer version (not app version) of 1.1.9 or higher as it requires Electron v21
23 |
24 | Credits
25 | - Kevin Powell Youtube channel
26 | */
27 |
28 | /* === Wide Page === */
29 |
30 | /* -- Main Code - EV & RV -- */
31 | body .wide-page { --file-line-width: 100%; }
32 |
33 |
34 | /* -- Special adjustment for Community Themes */
35 |
36 | /* Minimal */
37 | body[class*="minimal-tab-title"] .wide-page {
38 | --line-width: 100%;
39 | --max-width: 95%;
40 | --container-table-width: var(--line-width);
41 | --container-table-max-width: var(--max-width);
42 | }
43 |
44 | /* AnuPpuccin */
45 | /* body .wide-page { --anp-preview-width-pct: 100%; } */
46 |
47 |
48 | /* === Adjustable RLL === */
49 | /* cssClass toggle to allow users to adjust the RLL via Style Settings.
50 | Obsidian v1.0.0 makes it easier to do adjustable RLL ;) */
51 |
52 | /* -- Main Code - Editing and Reading View -- */
53 | body.is-adj-rll .view-content { --file-line-width: var(--adj-rll-max-width); }
54 |
55 |
56 |
57 | /* === Narrow Page === */
58 | /* cssClass YAML to allow users with disabled RLL to introduce RLL per
59 | page/note basis. width is following obsidian default setting, or you
60 | can change it via MCL's Adjustable RLL */
61 |
62 | /* -- Main Code - Editing and Reading View -- */
63 | .narrow-page.markdown-source-view .cm-sizer,
64 | .narrow-page.markdown-preview-view .markdown-preview-sizer {
65 | max-width: var(--file-line-width);
66 | margin-inline: auto;
67 | }
68 |
69 |
70 |
71 | /* === General Setups for Wide Blocks === */
72 |
73 | /* -- Setup for @container -- */
74 | :is(.wide-table-global, .wide-dataview-global, .wide-callout-global, .wide-backlinks-global) .markdown-source-view.is-readable-line-width,
75 | :is(.wide-table-global, .wide-dataview-global, .wide-callout-global, .wide-backlinks-global) .markdown-preview-view.is-readable-line-width,
76 | :is(.wide-table, .wide-dataview, .wide-callout, .wide-backlinks).markdown-source-view.is-readable-line-width,
77 | :is(.wide-table, .wide-dataview, .wide-callout, .wide-backlinks).markdown-preview-view.is-readable-line-width {
78 | container-name: content-view;
79 | container-type: inline-size;
80 | }
81 |
82 |
83 |
84 | /* === Wide Blocks - Wide Table === */
85 |
86 | /* -- Mai.n Code - EV & RV -- */
87 | body {
88 | --wide-tbl-left-ev-adj: -4rem;
89 | --wide-tbl-min-left-ev: 0.5rem;
90 | --wide-tbl-width-ev: calc( var(--file-line-width) - var(--wide-tbl-left-ev-adj) );
91 | }
92 | body:has(.cm-gutters) {
93 | --wide-tbl-left-ev-adj: 1rem;
94 | --wide-tbl-min-left-ev: 6rem;
95 | }
96 | @container content-view (width > 50px) {
97 | /* editing view */
98 | :is(.wide-table-global, .wide-table) .cm-embed-block.cm-table-widget {
99 | width: calc(100cqi - 4rem);
100 | margin-left: calc( max( 100cqi - var(--wide-tbl-width-ev), var(--wide-tbl-min-left-ev) ) / 2 * -1 ) !important;
101 | }
102 |
103 | /* reading view */
104 | :is(.wide-table-global .markdown-preview-view, .wide-table.markdown-preview-view) div:has(> table) {
105 | width: 100cqi;
106 | margin-left: calc( max( 100cqi - var(--file-line-width), 1rem ) / 2 * -1 ) !important;
107 | }
108 | /* centering the table a bit */
109 | :is(.wide-table-global, .wide-table) .cm-embed-block.cm-table-widget table,
110 | :is(.wide-table-global .markdown-preview-view, .wide-table.markdown-preview-view) div > table
111 | { margin-inline: auto; }
112 | }
113 |
114 |
115 | /* -- Special adjustment for Community Themes */
116 |
117 | /* Minimal, complete re-write for the theme due to many !important used by the theme */
118 | body[class*="minimal-tab-title"] {
119 | --wide-tbl-left-adj: -4rem;
120 | --wide-tbl-width-adj: 2rem;
121 | }
122 | body[class*="minimal-tab-title"]:has(.cm-gutters) {
123 | --wide-tbl-left-adj: -4rem;
124 | --wide-tbl-width-adj: 0rem;
125 | }
126 | body[class*="minimal-tab-title"]:has(.cm-gutters).minimal-theme {
127 | --wide-tbl-left-adj: 0rem;
128 | }
129 | @container content-view (width > 50px) {
130 | body[class*="minimal-tab-title"][class*="wide-table-global"] .markdown-source-view .cm-contentContainer.cm-contentContainer .cm-embed-block.cm-table-widget,
131 | body[class*="minimal-tab-title"] .wide-table.markdown-source-view .cm-contentContainer.cm-contentContainer .cm-embed-block.cm-table-widget {
132 | width: calc(100cqi - 4rem) !important;
133 | max-width: 100%;
134 | margin-left: calc( var(--wide-tbl-left-adj) / 2 * -1 ) !important;
135 | }
136 | body[class*="minimal-tab-title"][class*="wide-table-global"] .markdown-preview-view .markdown-preview-sizer div:has(> table),
137 | body[class*="minimal-tab-title"] .wide-table.markdown-preview-view .markdown-preview-sizer div:has(> table) {
138 | width: calc(100cqi - 2rem - var(--wide-tbl-width-adj) ) !important;
139 | max-width: 100%;
140 | margin-left: calc( var(--wide-tbl-left-adj) / 2 * -1 ) !important;
141 | }
142 | /* centering the table a bit */
143 | body[class*="minimal-tab-title"][class*="wide-table-global"] .markdown-source-view .cm-contentContainer.cm-contentContainer .cm-embed-block.cm-table-widget table,
144 | body[class*="minimal-tab-title"] .wide-table.markdown-source-view .cm-contentContainer.cm-contentContainer .cm-embed-block.cm-table-widget table,
145 | body[class*="minimal-tab-title"][class*="wide-table-global"] .markdown-preview-view .markdown-preview-sizer div > table,
146 | body[class*="minimal-tab-title"] .wide-table.markdown-preview-view .markdown-preview-sizer div > table
147 | { margin-inline: auto; }
148 | }
149 |
150 | /* Catppuccin */
151 | body[class*="ctp-"].is-adj-rll:not([class*="anp-default"]) { --wide-tbl-left-ev-adj: -8rem; }
152 |
153 |
154 |
155 | /* === Wide Blocks - Wide Dataview === */
156 | /* there are options to enable it (a) per page basis and (b) globally
157 | however, editing view is a hackaround */
158 |
159 | /* -- Main Code - EV & RV -- */
160 | body {
161 | --wide-dv-left-ev-adj: -4rem;
162 | --wide-dv-min-left-ev: 0.5rem;
163 | --wide-dv-width-ev: calc( var(--file-line-width) - var(--wide-dv-left-ev-adj) );
164 | }
165 | body:has(.cm-gutters) {
166 | --wide-dv-left-ev-adj: 1.7rem;
167 | --wide-dv-min-left-ev: 6.5rem;
168 | }
169 | @container content-view (width > 50px) {
170 | :is(.wide-dataview-global, .wide-dataview) .cm-preview-code-block:has(> .block-language-dataview),
171 | :is(.wide-dataview-global, .wide-dataview) .cm-preview-code-block:has(> .block-language-dataviewjs) {
172 | width: calc(100cqi - 4rem );
173 | margin-left: calc( max( 100cqi - var(--wide-dv-width-ev), var(--wide-dv-min-left-ev) ) / 2 * -1 ) !important;
174 | }
175 | :is(.wide-dataview-global, .wide-dataview) div:has(> .block-language-dataview),
176 | :is(.wide-dataview-global, .wide-dataview) div:has(> .block-language-dataviewjs) {
177 | width: 100cqi;
178 | margin-left: calc( max( 100cqi - var(--file-line-width), 1rem ) / 2 * -1 ) !important;
179 | }
180 | }
181 |
182 |
183 | /* -- Special adjustment for Community Themes */
184 |
185 | /* Minimal, complete re-write for the theme */
186 | body[class*="minimal-tab-title"] {
187 | --wide-dv-width-adj: 2rem;
188 | }
189 | body[class*="minimal-tab-title"]:has(.cm-gutters) {
190 | --wide-dv-left-ev-adj: -4rem;
191 | --wide-dv-width-adj: 0rem;
192 | }
193 | body[class*="minimal-tab-title"]:has(.cm-gutters).minimal-theme {
194 | --wide-dv-left-ev-adj: 0rem;
195 | }
196 | @container content-view (width > 50px) {
197 | body[class*="minimal-tab-title"][class*="wide-dataview-global"] .markdown-source-view .cm-contentContainer.cm-contentContainer .cm-content .cm-preview-code-block:has(> .block-language-dataview),
198 | body[class*="minimal-tab-title"] .wide-dataview.markdown-source-view .cm-contentContainer.cm-contentContainer .cm-content .cm-preview-code-block:has(> .block-language-dataview),
199 | body[class*="minimal-tab-title"][class*="wide-dataview-global"] .markdown-source-view .cm-contentContainer.cm-contentContainer .cm-content .cm-preview-code-block:has(> .block-language-dataviewjs),
200 | body[class*="minimal-tab-title"] .wide-dataview.markdown-source-view .cm-contentContainer.cm-contentContainer .cm-content .cm-preview-code-block:has(> .block-language-dataviewjs) {
201 | width: calc(100cqi - 4rem);
202 | max-width: 100%;
203 | margin-left: calc( var(--wide-dv-left-ev-adj) / 2 * -1 ) !important;
204 | }
205 | body[class*="minimal-tab-title"][class*="wide-dataview-global"] .markdown-preview-view div:has(> .block-language-dataview),
206 | body[class*="minimal-tab-title"] .wide-dataview.markdown-preview-view div:has(> .block-language-dataview),
207 | body[class*="minimal-tab-title"][class*="wide-dataview-global"] .markdown-preview-view div:has(> .block-language-dataviewjs),
208 | body[class*="minimal-tab-title"] .wide-dataview.markdown-preview-view div:has(> .block-language-dataviewjs) {
209 | width: calc(100cqi - 2rem - var(--wide-dv-width-adj) );
210 | max-width: 100%;
211 | margin-left: calc( var(--wide-dv-left-ev-adj) / 2 * -1 ) !important;
212 | }
213 | /* centering the table a bit */
214 | body[class*="minimal-tab-title"][class*="wide-dataview-global"] .markdown-source-view .cm-contentContainer.cm-contentContainer .cm-content table,
215 | body[class*="minimal-tab-title"] .wide-dataview.markdown-source-view .cm-contentContainer.cm-contentContainer .cm-content table,
216 | body[class*="minimal-tab-title"] .wide-dataview.markdown-preview-view .markdown-preview-sizer div > table {
217 | width: calc( 100% );
218 | }
219 | }
220 |
221 | /* Catppuccin */
222 | body[class*="ctp-"].is-adj-rll:not([class*="anp-default"]) { --wide-dv-left-ev-adj: -8rem; }
223 |
224 |
225 |
226 | /* === Wide Blocks - Wide Callout === */
227 | /* there are options to enable it (a) per page basis and (b) globally
228 | however, editing view is a hackaround
229 | !important needed because app's default uses it `.markdown-source-view.mod-cm6 .cm-content > *` */
230 |
231 | /* -- Main Code - EV & RV -- */
232 | body {
233 | --wide-co-left-ev-adj: -3.8rem;
234 | --wide-co-min-left-ev: 0.5rem;
235 | --wide-co-width-ev-adj: 4rem;
236 | --wide-co-width-ev: calc(var(--file-line-width) - var(--wide-co-left-ev-adj) );
237 | }
238 | body:has(.cm-gutters) {
239 | --wide-co-left-ev-adj: 1.7rem;
240 | --wide-co-min-left-ev: 6.5rem;
241 | }
242 | @container content-view (width > 50px) {
243 | :is(.wide-callout-global, .wide-callout) .cm-embed-block.cm-callout {
244 | width: calc( 100cqi - var(--wide-co-width-ev-adj) );
245 | margin-left: calc( max( 100cqi - var(--wide-co-width-ev), var(--wide-co-min-left-ev) ) / 2 * -1 ) !important;
246 | }
247 | :is(.wide-callout-global, .wide-callout) .markdown-preview-sizer > div:has(> .callout) {
248 | width: 100cqi;
249 | margin-left: calc( max( 100cqi - var(--file-line-width), 1rem ) / 2 * -1 ) !important;
250 | }
251 | }
252 |
253 |
254 | /* -- Special adjustment for Community Themes */
255 |
256 | /* Minimal, complete re-write for the theme */
257 | body[class*="minimal-tab-title"] { --folding-toggle: 1; }
258 | body.minimal-theme { --folding-toggle: 0; }
259 | body.minimal-theme:not(:has(.cm-gutters)) { --folding-toggle: 1; }
260 | @container content-view (width > 50px) {
261 | body[class*="minimal-tab-title"][class*="wide-callout-global"] .markdown-source-view .cm-contentContainer.cm-contentContainer .cm-content .cm-embed-block.cm-callout,
262 | body[class*="minimal-tab-title"] .wide-callout.markdown-source-view .cm-contentContainer.cm-contentContainer .cm-content .cm-embed-block.cm-callout {
263 | width: calc(100cqi - 4rem);
264 | max-width: 100%;
265 | margin-left: calc( var(--folding-offset) * var(--folding-toggle) ) !important;
266 | }
267 | body[class*="minimal-tab-title"][class*="wide-callout-global"] .markdown-preview-view .markdown-preview-sizer > div:has(> .callout),
268 | body[class*="minimal-tab-title"] .wide-callout.markdown-preview-view .markdown-preview-sizer > div:has(> .callout) {
269 | width: calc(100cqi - 2rem - 2rem * var(--folding-toggle) );
270 | max-width: calc(100% - 0rem);
271 | margin-left: calc( var(--folding-offset) * var(--folding-toggle) ) !important;
272 | }
273 | }
274 |
275 | /* AnuPpuccin */
276 | body[class*="anp-"] { --wide-co-width-ev-adj: 3.5rem; }
277 |
278 | /* Catppuccin */
279 | body[class*="ctp-"].is-adj-rll:not([class*="anp-default"]) { --wide-co-left-ev-adj: -7.8rem; }
280 |
281 |
282 |
283 | /* === Wide Blocks - Wide Backlinks === */
284 |
285 | /* -- Main Code - EV & RV -- */
286 | body {
287 | --wide-bl-left-ev-adj: 4rem;
288 | --wide-bl-width-ev: calc(var(--file-line-width) + var(--wide-bl-left-ev-adj) );
289 | }
290 | @container content-view (width > 50px) {
291 | :is(.wide-backlinks-global .markdown-source-view, .wide-backlinks.markdown-source-view) .embedded-backlinks {
292 | width: calc(100cqi - 3.5rem);
293 | margin-left: calc( max( 100cqi - var(--wide-bl-width-ev), 1rem ) / 2 * -1 );
294 | }
295 | :is(.wide-backlinks-global .markdown-preview-view, .wide-backlinks.markdown-preview-view) .embedded-backlinks {
296 | width: calc(100cqi - 0rem);
297 | margin-left: calc( max( 100cqi - var(--file-line-width), 1rem ) / 2 * -1 );
298 | }
299 | }
300 |
301 |
302 | /* -- Special adjustment for Community Themes */
303 |
304 | /* Minimal, complete re-write for the theme */
305 | body[class*="minimal-tab-title"] {
306 | --wide-bl-width-adj: 4rem;
307 | }
308 | body[class*="minimal-tab-title"]:has(.cm-gutters) {
309 | --wide-bl-width-adj: 0rem;
310 | }
311 | @container content-view (width > 50px) {
312 | body[class*="minimal-tab-title"][class*="wide-backlinks-global"] .markdown-source-view .cm-sizer .embedded-backlinks,
313 | body[class*="minimal-tab-title"] .wide-backlinks.markdown-source-view .cm-sizer .embedded-backlinks {
314 | width: calc(100cqi - 4.5rem);
315 | max-width: unset;
316 | margin-left: calc( var(--wide-bl-width-adj) / 2 * 1 ) !important;
317 | }
318 | body[class*="minimal-tab-title"][class*="wide-backlinks-global"] .markdown-preview-view .embedded-backlinks,
319 | body[class*="minimal-tab-title"] .wide-backlinks.markdown-preview-view .embedded-backlinks {
320 | width: calc( 100cqi - 2rem - var(--wide-bl-width-adj)/2 );
321 | margin-left: calc( max( 100cqi - var(--line-width) - var(--wide-bl-width-adj) , 4rem ) / 2 * -1 ) !important;
322 | }
323 | }
324 |
325 | /* Catppuccin */
326 | body[class*="ctp-"].is-adj-rll:not([class*="anp-default"]) { --wide-bl-left-ev-adj: 13.5rem; }
327 |
328 |
329 |
330 | /* @settings
331 |
332 | name: Modular CSS Layout - Wide Views
333 | id: modular-css-layout-wv
334 | settings:
335 |
336 | -
337 | id: adj-rll-title
338 | title: Adjustable RLL Settings
339 | description: Control max-width for all page/note by default. RLL must be **enabled**
340 | type: heading
341 | level: 2
342 | collapsed: true
343 | -
344 | id: is-adj-rll
345 | title: Enable Adjustable RLL
346 | description: Add is-adj-rll class to the body element
347 | type: class-toggle
348 | -
349 | id: adj-rll-max-width
350 | title: Max Width for Normal Width page
351 | description: Can use any unit e.g. px, em, ch
352 | type: variable-text
353 | default: 700px
354 |
355 | -
356 | id: wide-view-title
357 | title: Vault-wide toggle for Wide Blocks
358 | description: For wide -table/-dataview/-callout/-backlinks. RLL must be **enabled**
359 | type: heading
360 | level: 2
361 | collapsed: true
362 | -
363 | id: wide-dataview-global
364 | title: Enable `wide-dataview` vault-wide
365 | description: use `wide-dataview` in yaml to enable only for selected note/page
366 | type: class-toggle
367 | -
368 | id: wide-table-global
369 | title: Enable `wide-table` vault-wide
370 | description: use `wide-table` in yaml to enable only for selected note/page
371 | type: class-toggle
372 | -
373 | id: wide-callout-global
374 | title: Enable `wide-callout` vault-wide
375 | description: use `wide-callout` in yaml to enable only for selected note/page
376 | type: class-toggle
377 | -
378 | id: wide-backlinks-global
379 | title: Enable `wide-backlinks` vault-wide
380 | description: use `wide-backlinks` in yaml to enable only for selected note/page
381 | type: class-toggle
382 |
383 | -
384 | id: narrow-view-title
385 | title: Narrow Page Settings
386 | description: Control max-width page/note with cssClass `narrow-page`. RLL must be **disabled**
387 | type: heading
388 | level: 2
389 | collapsed: true
390 | -
391 | id: narrow-max-width
392 | title: Max Width for Narrow View page (any unit e.g. px, em, ch)
393 | type: variable-text
394 | default: 750px
395 |
396 | */
397 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Modular CSS Layout for Obsidian
2 |
3 |    
4 |
5 |
6 | This is a repository for modular CSS layout hack for use with [Obsidian.md](https://obsidian.md/). It's meant to complement/assist Community Theme, focusing solely on providing alternative layout to standard width and standard top-bottom block view.
7 |
8 | I mainly do casual test on select popular themes like ITS, Primary, Shimmering Focus, Prism, and Minimal. Need your help to let me know if there's anything not working right. Do log in [MCL GH Issue](https://github.com/efemkay/obsidian-modular-css-layout/issues) if you find anything not working properly.
9 |
10 | ### Table of Content
11 | - [Install/Download](#installation--download-and-enable)
12 | - [Wide Views](#wide-views)
13 | - [Multi Column](#multi-column)
14 | - [Gallery Cards](#gallery-cards)
15 | - [Support Me](#support-me)
16 |
17 |
18 |
19 | ## Installation / Download and Enable
20 |
21 | This is actually just a CSS code snippets collection. So it isn't an installation per se, but rather download and enable in Obsidian. The best way is to use Mara Li's [Snippet Downloader](https://github.com/Mara-Li/obsidian-snippet-downloader) plugin as I have plans to update this snippets from time to time
22 |
23 |
24 |
25 | ## Wide Views
26 | > CSS snippet: `MCL Wide Views.css`
27 |
28 | > This section only briefly explains Wide Views snippet. Please go through the documentation site [Wide Views - Modular CSS Layout](https://efemkay.github.io/obsidian-modular-css-layout/wide-views/) for more details.
29 |
30 | This snippet provides you the following features:
31 | - Full width page or blocks (dataview, table and backlinks) per page/note basis by specifying custom `cssClass` at the frontmatter (YAML)
32 | - `wide-page`
33 | - `wide-dataview`
34 | - `wide-table`
35 | - `wide-callout`
36 | - `wide-backlinks`
37 | - vault-wide toggle for each of the above
38 | - Narrow width page per page/note basis for vault with RLL disabled by specifying custom `cssClass` at the frontmatter (YAML)
39 | - `narrow-page`
40 | - Adjustable RLL (custom css class toggle) applicable to entire vault
41 | - Disabled by default. Enable it via Style Settings plugin
42 |
43 | > [!TIP]
44 | > Thanks to Obsidian updated Electron base to V21, I have managed to avoid using Contextual Typography plugin to support wide blocks with the release of [v0.9.6](https://github.com/efemkay/obsidian-modular-css-layout/releases/tag/0.9.6)
45 |
46 |
47 | #### Example
48 |
49 | ```markdown
50 | ---
51 | cssClass: wide-page
52 | ---
53 |
54 |
55 | ```
56 |
57 |
58 |
59 |
60 |
61 | ## Multi Column
62 | > CSS snippet: `MCL Multi Column.css`
63 | >
64 | > This section only briefly explains Multi Column snippet. Please go through the documentation site [Multi Column - Modular CSS Layout](https://efemkay.github.io/obsidian-modular-css-layout/multi-column/) for more details.
65 |
66 | This snippet provides you the following features:
67 | - Multi Column layout using Callout i.e. `> [!multi-column]`
68 | - List Column/Grid/Card layout using (Unordered) list by either (a) using tag, (b) using Markdown Attributes plugin, or (c) specifying in the frontmatter (YAML)
69 | - Float (Aside) Callout using callout metadata e.g. `> [!info|right-medium]`
70 |
71 | ### Multi Column Callout
72 |
73 | Multi Column Callout layout take advantage of Obsidian Callout - leveraging it as parent ‘div’ to house the sub callout (including Dataview results block). You can nest as many sub-callouts within it. The sub-callout will expand if [!multi-column] callout has extra space or overflow to next row if it doesn’t.
74 |
75 | 
76 |
77 | #### Example of Multi Column Callout
78 | > *Example below is for the three callouts side-by-side in the picture above*
79 |
80 | > [!multi-column]
81 | >
82 | >> [!note]+ Use Case
83 | >> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
84 | >> ##### User Case Background
85 | >> Vitae nunc sed velit dignissim sodales. In cursus turpis massa tincidunt dui ut ornare lectus.
86 | >
87 | >> [!warning]+ Resources
88 | >> #### Requirement
89 | >> - Lorem ipsum dolor sit amet
90 | >> - Vitae nunc sed velit dignissim sodales.
91 | >> - In cursus turpis massa tincidunt dui ut ornare lectus.
92 | >
93 | >> [!todo]+
94 | >> - [x] Define Use Case
95 | >> - [ ] Craft User Story
96 | >> - [ ] Develop draft sketches
97 |
98 |
99 | > note that when you insert callout within callout, the line separating the callouts should only use single angle bracket (">")
100 |
101 |
102 | ### List Column/Grid/Card
103 | This layout take advantage of markdown unordered list (i.e. `- list item`) to create multi column (and multi row for List Grid/Card) layout by matching with an identifier i.e. either `#mcl` tag, Markdown Attributes plugin syntax, or `cssclass:` key at frontmatter.
104 |
105 | 
106 |
107 | Here are quick reference on the syntax for List Column/Grid/Card
108 |
109 | | Type | Using Tag | MD Attr plugin | Frontmatter |
110 | |---|---|---|---|
111 | | LCol |`#mcl/list-column`|`two-column-list-block` `three-column-list-block` `four-column-list-block` `multi-column-list-block`|`two-column-list` `three-column-list` `four-column-list` `multi-column-list`|
112 | | LGrd |`#mcl/list-grid` `#mcl/list-grid-wide`|-|`two-column-grid-list` `three-column-grid-list`|
113 | | LCrd |`#mcl/list-card` `#mcl/list-card-wide`|-|-|
114 |
115 | > Note: LCol = List Column // LGrd = List Grid // LCrd = List Card
116 |
117 |
118 | #### Example of List Grid
119 | *Example below is for the "Goals and Objectives" in the picture above*
120 |
121 | ```markdown
122 | ## List Grid Example - Goals and Objectives
123 |
124 | - #### Core Work #mcl/list-grid
125 | - [[00 Home|Main Goal 1]]
126 | - [[00 Home|Main Goal 2]]
127 | - [[00 Home|Main Goal 3]]
128 | - Collaboration with Jane
129 | - [[00 Home|Main Goal 4]]
130 | - #### Learning & System
131 | - [[00 Home|Learning Goal 1]]
132 | - [[00 Home|Initiative 1]]
133 | - [[00 Home|Initiative 2]]
134 | - #### Personal
135 | - [[00 Home|Personal Goal 1]]
136 | - [[00 Home|Personal Goal 2]]
137 | ```
138 |
139 |
140 | ### Float Callout
141 |
142 | Float Callout will allow you to position side note or info box either to the left or right of the main note with other content wrapping around it. It uses callout-metadata to specify which side to float to and the size of the callout
143 |
144 | You can apply to any callout as the identifier is done on the callout-metadata i.e. after the `|` in `[!|]`. Table below gives some understanding of the syntax structure.
145 |
146 | |Apply in LP? | Which Side? | Preset FC Size | Example |
147 | |---|---|---|---|
148 | |`` `float`|`left` `right`|`small` `medium` `large`| `[!info\|float-right-medium]` `[!blank\|right-small]`|
149 |
150 |
151 |
152 | ## Gallery Cards
153 | > CSS snippet: `MCL Gallery Cards.css`
154 | >
155 | > This section only briefly explains Gallery Cards snippet. Please go through the documentation site [Gallery Cards - Modular CSS Layout](https://efemkay.github.io/obsidian-modular-css-layout/gallery-cards/) for more details.
156 |
157 | This snippet provides you the following features:
158 | - Image gallery using callout by specifying the callout-metadata `gallery` e.g. `> [!NOTE|gallery]`
159 | - Image gallery using YAML/frontmatter .`cssClass: image-gallery`
160 | - Float Image using image alt-text
161 | - Image and Mermaid Diagram Controls
162 | - Dimension control for images in bullet list
163 | - Image Zoom
164 | - Mermaid Scale and Zoom
165 |
166 | ### Float Image
167 | Float Image is similar to Float Callout but apply directly to the images (doesn’t require you to wrap it in a callout). Currently it uses image caption to identify how you want to float it, but in the future I intend to make it work with anchor tag `#` as well.
168 |
169 | 
170 |
171 | You can apply to any image as the identifier is done on the alt-text i.e. after the `|` in `[[path/to/image.jpg|alt-text]]` or the text inside `[]` in `[alt-text](path/to/image.jpg)`. Table below gives some understanding of the syntax structure.
172 |
173 | |Apply in LP? | Which Side? | Preset FC Size | Example |
174 | |---|---|---|---|
175 | |`` `float`|`left` `right`|`small` `medium` `large`| `[[image.jpg\|float-right-medium]]` `[right-small](image.jpg)`|
176 |
177 |
178 |
179 | ## Support Me
180 | I do this on my free time for personal joy. However, a cup of coffee or two would motivate me further! If you like what I do, and want to contribute back, you can support me via Ko-fi
181 |
182 |
183 |
--------------------------------------------------------------------------------
/Showcases/Float with Multi Column Dataview/MCL Showcase - Float with Multi Column Dataview.md:
--------------------------------------------------------------------------------
1 | ---
2 | cssclass: text-justify
3 | ---
4 |
5 | ## General linear model
6 |
7 | > [!blank-container|right-medium no-margin] Relationship of Data, Information and Intelligence
8 | > ![[Pasted image 20220424085124.png]]
9 | > Example of [simple linear regression](https://en.wikipedia.org/wiki/Simple_linear_regression "Simple linear regression"), which has one independent variable
10 |
11 | The **general linear model** or **general multivariate regression model** is a compact way of simultaneously writing several [multiple linear regression](https://en.wikipedia.org/wiki/Multiple_linear_regression "Multiple linear regression") models. In that sense it is not a separate statistical [linear model](https://en.wikipedia.org/wiki/Linear_model "Linear model"). The various multiple linear regression models may be compactly written as $Y=XB + U$
12 |
13 | The general linear model incorporates a number of different statistical models: ANOVA, ANCOVA, MANOVA, MANCOVA, ordinary linear regression, _t_-test and _F_-test. The general linear model is a generalization of multiple linear regression to the case of more than one dependent variable. If **Y**, **B**, and **U** were column vectors, the matrix equation above would represent multiple linear regression.
14 |
15 | Hypothesis tests with the general linear model can be made in two ways: multivariate or as several independent univariate tests. In multivariate tests the columns of **Y** are tested together, whereas in univariate tests the columns of **Y** are tested independently, i.e., as multiple univariate tests with the same design matrix.
16 |
17 | ## Other Notes on Regression Model
18 | > [!multi-column]
19 | >
20 | > ```dataview
21 | > table without id file.link as "Statistical Analysis"
22 | > from "sample data A"
23 | > ```
24 | >
25 | > ```dataview
26 | > table without id file.link as "Regression"
27 | > from "sample data B"
28 | > ```
29 | >
30 | > ```dataview
31 | > table without id file.link as "Model Validation"
32 | > from "sample data C"
33 | > ```
34 |
35 | > sample text extracted from [General linear model - Wikipedia](https://en.wikipedia.org/wiki/General_linear_model) and [Linear regression - Wikipedia](https://en.wikipedia.org/wiki/Linear_regression#Simple_and_multiple_linear_regression)
36 | ---
37 |
38 | > [!multi-column]
39 | >> [!NOTE]+ How to use?
40 | >> - To achieve this note layout, download `MCL Multi Column.css` to your snippets. It uses the following custom callout to achieve the look
41 | >> - `[!blank-container|right-medium]` - to float to the right
42 | >> - `[!multi-column]` with dataview code blocks inside - to achieve the three column dataview
43 | >
44 | >> [!Warning]+ Compatibility issue with some themes
45 | >> - The float does not work well with blockquotes and callout box formatting. It depends on the theme developer way of formatting them
46 | >>> Example here uses **Mado 11** theme by *hydescarf*. No changes made to theme (in term of color, formatting and decoration) other than the layout. MCL is meant to be used in tandem with most community theme.
--------------------------------------------------------------------------------
/Showcases/Float with Multi Column Dataview/MCL Showcase – Float with Multi Column Dataview.PNG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/Showcases/Float with Multi Column Dataview/MCL Showcase – Float with Multi Column Dataview.PNG
--------------------------------------------------------------------------------
/Showcases/Multi Column Callout and List/MCL Showcase - MC Callout and List.md:
--------------------------------------------------------------------------------
1 | ---
2 | cssclass: wide-page
3 | ---
4 |
5 | > [!multi-column]
6 | > > [!Todo]+ Deliverables Milestone
7 | > > - [x] Insider's Alpha Release
8 | > > - [ ] Gold & Silver Supporters Meetup
9 | > > - [ ] Public Beta Release
10 | >
11 | > > [!Summary]+ Funding Milestone
12 | > > - Series A: $ 1.1 mil
13 | > > - Series B: ongoing
14 | > > - Series C: planned
15 |
16 | ## Project Background
17 | Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Interdum velit euismod in pellentesque massa placerat duis. Bibendum arcu vitae elementum curabitur vitae nunc. Quis ipsum suspendisse ultrices gravida. Risus in hendrerit gravida rutrum quisque non tellus.
18 |
19 | #### Use Case
20 | Viverra mauris in aliquam sem fringilla ut morbi tincidunt. Faucibus pulvinar elementum integer enim neque volutpat ac tincidunt vitae. Urna et pharetra pharetra massa massa ultricies. Ultrices eros in cursus turpis massa tincidunt. Ullamcorper velit sed ullamcorper morbi. Ornare quam viverra orci sagittis eu. Tortor dignissim convallis aenean et tortor at.
21 | - Consectetur adipiscing elit ut aliquam purus sit amet luctus.
22 | - Est lorem ipsum dolor sit. Blandit cursus risus at ultrices mi.
23 | - Vestibulum mattis ullamcorper velit sed ullamcorper. In mollis nunc sed id semper risus in.
24 | {.two-column-list-block}
25 |
26 | ## Supporters
27 | - **Nina** (Gold)
28 | - **Frankie** (Silver)
29 | - **Nurul** (Silver)
30 | - **Kamala** (Silver)
31 | - Nguyen
32 | - Cypher
33 | - Powell
34 | - Sam
35 | - Kate
36 | - Roger
37 | - Sharon
38 | - Peter
39 | - Obadiah
40 | - Serena
41 | - Nicholas
42 | {.multi-column-list-block}
43 |
44 | ---
45 |
46 | > [!NOTE]+ How to achieve the look?
47 | > - This note layout will require the following snippet and plugin
48 | > - `MCL Multi Column.css` css snippet for the multi-column callout,
49 | > - [Markdown Attributes](https://github.com/valentine195/obsidian-markdown-attributes) plugin for the multi-column unordered list, and
50 | > - Optional. `MCL Wide Views.css` css snippet for the wide-page view
51 | > - To get the multi-column callout, use `[!multi-column]` custom callout and nest two standard callouts (i.e. `[!todo]` and `[!summary]`) within it.
52 | > - Ensure that these nested callout has double angle bracket (`>>`) to indicate they are nested within and the spacing between the nested callout have only single angle bracket (`>`)
53 | > - To get the multi-column unordered list, type `{.multi-column-list-block}` on a new line immediately after the last bullet.
54 | > - Using Style Settings plugin, set the **MCL - Multi Column > List Column Settings > Minimum Column Width** to 100px (if you want to have at least two columns in mobile phone view, else just leave it at default (200px)).
55 | > - Note that this multi column list will not render in editing view (not even in live preview mode). It will also require Markdown Attributes plugin installed and enabled.
56 |
57 | > [!Warning]+ Potential Issues
58 | > - Markdown won't render properly if the multi-column list has a sublist (2nd level indent list) as the very end.
59 | > - This is due to Markdown Attributes plugin require it to be on the new line immediately after the list, but Obsidian will be confused with two level indent followed by non-bullet text.
60 | > - Box shadown on certain themes may look a bit off for a sharp eye.
61 | > - Some theme heavily customise their callout, as such you may notice that box shadow does not appear round on the inner border (that are facing another sub-callout, for theme that uses border-radius features).
62 |
63 |
--------------------------------------------------------------------------------
/Showcases/Multi Column Callout and List/MCL Showcase - MC Callout and List.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/Showcases/Multi Column Callout and List/MCL Showcase - MC Callout and List.png
--------------------------------------------------------------------------------
/docs/_config.yml:
--------------------------------------------------------------------------------
1 | remote_theme: just-the-docs/just-the-docs
2 |
3 | # Site settings
4 | title: Modular CSS Layout
5 | description: Modular CSS Layout for Obsidian
6 | baseurl: "/obsidian-modular-css-layout" # the subpath of your site, e.g. /blog
7 | url: "https://efemkay.github.io" # the base hostname & protocol for your site, e.g. http://example.com
8 |
9 | permalink: pretty
10 |
11 | # Site Logo -- i don't have one (yet)
12 | # Site Search -- I maintained the default (which is enabled with some others like depth and so on
13 |
14 | # Mermaid diagrams -- I include this because it's an opt-in
15 | mermaid:
16 | version: "9.1.6" # Pick an available version from https://cdn.jsdelivr.net/npm/mermaid/
17 |
18 | # Aux links for the upper right navigation
19 | aux_links:
20 | "MCL on GitHub":
21 | - "//github.com/efemkay/obsidian-modular-css-layout"
22 |
23 | # Makes Aux links open in a new tab. Default is false
24 | aux_links_new_tab: false
25 |
26 | # Color scheme currently only supports "dark", "light"/nil (default), or a custom scheme that you define
27 | color_scheme: dark
28 |
29 | callouts_level: quiet # or loud
30 | callouts:
31 | highlight:
32 | color: yellow
33 | important:
34 | title: Important
35 | color: blue
36 | new:
37 | title: New
38 | color: green
39 | note:
40 | title: Note
41 | color: purple
42 | warning:
43 | title: Warning
44 | color: red
45 |
--------------------------------------------------------------------------------
/docs/_sass/custom/custom.scss:
--------------------------------------------------------------------------------
1 | // custom SCSS (or CSS) goes here
2 |
3 |
4 | /* adjustment to callouts. change text color and some padding */
5 |
6 | p.note-title>p:first-child, blockquote.note-title>p:first-child {
7 | margin-bottom: 1em;
8 | color: hsl(258, 69%, 70%);
9 | }
10 |
11 | blockquote.note-title > ul:last-child {
12 | margin-bottom: 0.5em
13 | }
14 |
--------------------------------------------------------------------------------
/docs/_sass/custom/setup.scss:
--------------------------------------------------------------------------------
1 | // custom SCSS (or CSS) goes here
2 |
3 |
4 | // adjustment to callouts. change text color and some padding */
5 |
6 | p.note-title>p:first-child, blockquote.note-title>p:first-child {
7 | margin-bottom: 1em;
8 | color: hsl(258, 69%, 70%);
9 | }
10 |
11 | blockquote.note-title > ul:last-child {
12 | margin-bottom: 0.5em
13 | }
14 |
--------------------------------------------------------------------------------
/docs/assets/gallery-callout-langkawi.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/gallery-callout-langkawi.png
--------------------------------------------------------------------------------
/docs/assets/gallery-cards-settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/gallery-cards-settings.png
--------------------------------------------------------------------------------
/docs/assets/gallery-cssclass-langkawi.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/gallery-cssclass-langkawi.png
--------------------------------------------------------------------------------
/docs/assets/gallery-mermaid-scale.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/gallery-mermaid-scale.png
--------------------------------------------------------------------------------
/docs/assets/gc-ss-for-obsd-forum.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/gc-ss-for-obsd-forum.png
--------------------------------------------------------------------------------
/docs/assets/hero-gc-float-image.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/hero-gc-float-image.png
--------------------------------------------------------------------------------
/docs/assets/hero-mc-callout.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/hero-mc-callout.png
--------------------------------------------------------------------------------
/docs/assets/hero-mc-list-column-grid-card.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/hero-mc-list-column-grid-card.png
--------------------------------------------------------------------------------
/docs/assets/how to install and enable MCL.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/how to install and enable MCL.gif
--------------------------------------------------------------------------------
/docs/assets/how-to-install-mcl.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/how-to-install-mcl.gif
--------------------------------------------------------------------------------
/docs/assets/installing-mcl-snippets.mp4:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/installing-mcl-snippets.mp4
--------------------------------------------------------------------------------
/docs/assets/installing-mcl-snippets.webm:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/installing-mcl-snippets.webm
--------------------------------------------------------------------------------
/docs/assets/mc-blob-page.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-blob-page.png
--------------------------------------------------------------------------------
/docs/assets/mc-callout-fixed-width.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-callout-fixed-width.png
--------------------------------------------------------------------------------
/docs/assets/mc-callout-standard.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-callout-standard.png
--------------------------------------------------------------------------------
/docs/assets/mc-callout-width-control.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-callout-width-control.png
--------------------------------------------------------------------------------
/docs/assets/mc-callout-within-mc-callout.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-callout-within-mc-callout.jpg
--------------------------------------------------------------------------------
/docs/assets/mc-float-callout.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-float-callout.png
--------------------------------------------------------------------------------
/docs/assets/mc-list-card.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-list-card.png
--------------------------------------------------------------------------------
/docs/assets/mc-list-column.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-list-column.png
--------------------------------------------------------------------------------
/docs/assets/mc-list-grid.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-list-grid.png
--------------------------------------------------------------------------------
/docs/assets/mc-ss-for-obsd-forum.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/mc-ss-for-obsd-forum.png
--------------------------------------------------------------------------------
/docs/assets/multi-column-callout-settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/multi-column-callout-settings.png
--------------------------------------------------------------------------------
/docs/assets/multi-column-list-settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/multi-column-list-settings.png
--------------------------------------------------------------------------------
/docs/assets/note.md:
--------------------------------------------------------------------------------
1 | placeholder
2 |
--------------------------------------------------------------------------------
/docs/assets/showcases/showcase-float-mc-dataview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/showcases/showcase-float-mc-dataview.png
--------------------------------------------------------------------------------
/docs/assets/showcases/showcase-mc-callout-and-list-card.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/showcases/showcase-mc-callout-and-list-card.png
--------------------------------------------------------------------------------
/docs/assets/showcases/showcase-mc-callout-and-list.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/showcases/showcase-mc-callout-and-list.png
--------------------------------------------------------------------------------
/docs/assets/showcases/wide-table-example-anp.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/showcases/wide-table-example-anp.gif
--------------------------------------------------------------------------------
/docs/assets/wide-views-settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/assets/wide-views-settings.png
--------------------------------------------------------------------------------
/docs/gallery-cards/02-image-gallery.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Image Gallery
3 | parent: Gallery Cards
4 | nav_order: 2
5 | ---
6 |
7 | # Image Gallery
8 | {: .no_toc }
9 |
10 | `last update: 06 July 2023`
11 |
12 | ## Table of Contents
13 | {: .no_toc .text-delta }
14 |
15 | 1. TOC
16 | {:toc}
17 |
18 |
19 | ## Overview
20 |
21 | Image Gallery layout will allow you to create masonry like image gallery layout by placing image embed (i.e. `![[path/to/image.jpg]]`) in successive row of line. There are 2 different ways you can do so i.e.
22 |
23 | 1. Using Obsidian Callout (by specifying the callout metadata `gallery`)
24 | 2. Using frontmatter (by specifying `cssclass: image-gallery`)
25 |
26 | {: .warning-title}
27 | > Markdown image embed (i.e. ``) not supported
28 | >
29 | > Due to how Obsidian renders markdown image embed, I currently cannot implement Image Gallery using such syntax. So for this part, always use wikilink embed (i.e. `![[path/to/image.jpg]]`)
30 |
31 |
32 |
33 | ### How to Use -- with Callout
34 |
35 | - Insert callout (it will work with any callout) and enter `gallery` in the callout metadata. E.g. `> [!info|gallery]`
36 | - Insert transcluded/embedded images. Add empty lines in between the images to create new row. Images "grouped" between empty lines will be stacked side by side
37 |
38 | ```markdown
39 | > [!blank-container|no-margin gallery] Title
40 | >
41 | > ![[path/to/pic1.jpg]]
42 | > ![[path/to/pic2.jpg]]
43 | >
44 | > ![[path/to/pic3.png]]
45 | > ![[path/to/pic4.png]]
46 | > ![[path/to/pic5.png]]
47 |
48 | ```
49 |
50 | #### Example
51 |
52 | 
53 |
54 |
55 | ### How to Use -- with Frontmatter `cssClass: image-gallery`
56 |
57 | - Specify `cssClass: image-gallery` at the frontmatter *(top of your markdown notes fenced by two three-dashes `---`, see example below)*
58 | - Insert embedded images (i.e. `![[path/to/image.jpg]]`). Put next to each other (with single spacing) for same row placement. Add single empty line to create new row.
59 |
60 |
61 | ```markdown
62 | ---
63 | cssClass: image-gallery
64 | ---
65 |
66 | ![[path/to/pic1.jpg]] ![[path/to/pic2.jpg]]
67 |
68 | ![[path/to/pic3.png]] ![[path/to/pic4.png]] ![[path/to/pic5.png]]
69 |
70 | ```
71 |
72 | > Note that with frontmatter declaration, you have to put the image embed syntax on same line if you want it to stack side by side in LP. Reading View is more robust and is okay with single line break for same row and empty line for creating new row
73 | >
74 | > **Syntax below only works with Reading View**
75 | > ```markdown
76 | > ---
77 | > cssClass: image-gallery
78 | > ---
79 | >
80 | > ![[path/to/pic1.jpg]]
81 | > ![[path/to/pic2.jpg]]
82 | >
83 | > ![[path/to/pic3.png]]
84 | > ![[path/to/pic4.png]]
85 | > ![[path/to/pic5.png]]
86 | >
87 | > ```
88 |
89 |
90 |
91 | #### Example
92 |
93 | 
94 |
95 |
96 | ## Credits
97 |
98 | - Pictures in Gallery example are from Unsplash
99 | - [@ryaneof](https://unsplash.com/photos/Jh_Xk8RQtG0)
100 | - [@manish_tulaskar](https://unsplash.com/photos/o0TRwfgXhdw)
101 | - [@izuddinhelmi](https://unsplash.com/photos/dIArrAUjQV0)
102 | - [@jaysithutun](https://unsplash.com/photos/0dF2fJjTHCw)
103 | - [@ramzigraphy](https://unsplash.com/photos/WeiERYmWIT4)
104 |
--------------------------------------------------------------------------------
/docs/gallery-cards/03-image-control.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Image Control
3 | parent: Gallery Cards
4 | nav_order: 3
5 | ---
6 |
7 | # Image Control
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ## Image and Mermaid Diagram Controls
17 |
18 | ### Dimension control for images in bullet list
19 | - By default, this feature is **enabled** when you apply the snippet. To disable, go to Style Settings and under `Modular CSS Layout - Gallery Cards > Image in List Settings` enable the "Disable Control for Image in List"
20 | - You may also specify the max dimension for images in bullet list via the Style Settings
21 |
22 | ### Image Zoom
23 | - To enable this feature, go to Style Settings and under `Modular CSS Layout - Gallery Cards > General Image Settings` enable the "Enable Image Zoom via CSS"
24 |
25 | ### Mermaid Scale and Zoom
26 | - By default, Mermaid diagram scale (i.e. fit-to-width) feature is **enabled** when you apply the snippet. To disable, go to Style Settings and under `Modular CSS Layout - Gallery Cards > Mermaid Scale & Zoom Settings` enable the "Disable Control for Image in List"
27 | - To enable Mermaid diagram zoom feature, go to Style Settings and under `Modular CSS Layout - Gallery Cards > Mermaid Scale & Zoom Settings` enable the "Enable Mermaid Zoom via CSS"
28 |
29 | > Note that with Obsidian v0.16.x zoom via CSS in Editing View is broken, you may only use it in Reading View
30 |
31 | #### Example
32 | 
33 |
--------------------------------------------------------------------------------
/docs/gallery-cards/04-image-float.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Float Image
3 | parent: Gallery Cards
4 | nav_order: 4
5 | ---
6 |
7 | # Float Image
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ## Overview
17 |
18 | Float Image is similar to Float Callout but apply directly to the images (doesn't require you to wrap it in a callout). Currently it uses image caption to identify how you want to float it, but in the future I intend to make it work with anchor tag `#` as well.
19 |
20 | ### How to Use / Basic Syntax
21 |
22 | 1. Add your image (either internal or external) as per normal
23 | 2. Add `left` or `right` to the image caption (similar to markdown display text i.e. `|`) e.g. `![[image.jpg|right]]`
24 |
25 | > You can still specify image width per normal if you desire, just make sure the width is the last syntax before closing bracket `]]`, e.g. below
26 | >
27 | > `![[ryaneof-Jh_Xk8RQtG0-unsplash.jpg|right|300]]`
28 |
29 | Here's an example markdown
30 |
31 | ```markdown
32 | ### Main Article
33 |
34 | ![[ryaneof-Jh_Xk8RQtG0-unsplash.jpg|right|350]]
35 |
36 | Content of the main article
37 | ```
38 |
39 |
40 |
41 | ## Additional Controls (and Notes)
42 |
43 | ### Apply to Live Preview
44 |
45 | By default, if you only specify either `left` or `right`, Float Image will only work in Reading View. If you want it to also work in Live Preview, prepend `float-` before the `left` or `right` e.g. `![[image.jpg|float-right]]`
46 |
47 | Here's an example markdown
48 |
49 | ```markdown
50 | ## Main Article
51 |
52 | ![[ryaneof-Jh_Xk8RQtG0-unsplash.jpg|float-right|350]]
53 |
54 | Content of the main article
55 | ```
56 |
57 | > **Note on Editing in Live Preview**
58 | >
59 | > In previous version of Float Image, editing text next to it was quite janky. I've improved it a bit (for `float-right` at least). For `float-left` you may still find selecting and navigating the text (up and down) still not possible.
60 | >
61 | > To edit, it's better to navigate using keyboard (from the top or bottom) instead of mouse/trackpad. Even better, use Source Mode to edit.
62 |
63 |
64 | ### External Images
65 |
66 | Technically, the image float positioning can work with external link images but it is currently not aesthetically optimised (in term of gaps and other adjustment).
67 |
68 | I will update this in the future. But if you must use it now, the syntax is `![|]()` and `![float-|]()`
69 |
--------------------------------------------------------------------------------
/docs/gallery-cards/05-gc-settings.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Gallery Cards Settings
3 | parent: Gallery Cards
4 | nav_order: 5
5 | ---
6 |
7 | # Gallery Cards Style Settings
8 |
9 |
10 | ## General Image Settings
11 |
12 | | Settings | Description |
13 | | --- | --- |
14 | | Enable Image Zoom via CSS | Switch to enable click to zoom image to full-screen |
15 | | Image Border Radius | Set the "curve" for images in `[!\|gallery]` |
16 |
17 |
18 | ## Image in "Gallery" Settings
19 | "Gallery" refers to gallery callout-metadata and/or "cssClass:image-gallery" frontmatter
20 |
21 | | Settings | Description |
22 | | --- | --- |
23 | | Hide Strange New World Indicators | Hide Strange New World count indicator in Image Gallery (both using callout and css helper) |
24 | | Gallery Callout Gap | Set the gap between images in `[!\|gallery]` |
25 | | Max Height for Images | Set the max height for Images in `[!\|gallery]` and `cssClass: image-gallery` |
26 | | Max Width for Images | Set the max width for Images in `[!\|gallery]` and `cssClass: image-gallery` |
27 |
28 |
29 | ## Image in Lists Settings
30 |
31 | | Settings | Description |
32 | | --- | --- |
33 | | Disable Image Control in Lists | Turn this on to have the max height and width set below to have effect to images in bullet list |
34 | | Max Height for Images in Lists | Set the max height for Images in `[!\|gallery]` and `cssClass: image-gallery` |
35 | | Max Width for Images in Lists | Set the max width for Images in `[!\|gallery]` and `cssClass: image-gallery` |
36 |
37 |
38 | ## Mermaid SVG Settings
39 |
40 | | Settings | Description |
41 | | --- | --- |
42 | | Disable scaling for Mermaid diagram | Default is disabled. Turn this off to have Mermaid diagram not scaled to note's width |
43 | | Enable Image Zoom via CSS | Default is enabled. Turn this off to not have image zoom via CSS |
44 |
45 | ---
46 |
47 |
48 |
--------------------------------------------------------------------------------
/docs/gallery-cards/index.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Gallery Cards
3 | nav_order: 5
4 | has_children: true
5 | ---
6 |
7 | # Gallery Cards
8 |
9 | > CSS snippet file: [MCL Gallery Cards.css](https://github.com/efemkay/obsidian-modular-css-layout/blob/main/MCL%20Gallery%20Cards.css)
10 |
11 | Gallery Cards CSS snippet will allow you to create image gallery and control image customisation (like rounded corner and max width). In summary this snippet will provide the following features:
12 | - Image gallery using callout by specifying the callout-metadata `gallery` e.g. `> [!NOTE|gallery]`
13 | - Image gallery using YAML/frontmatter .`cssClass: image-gallery`
14 | - Image and Mermaid Diagram Controls
15 | - Dimension control for images in bullet list
16 | - Image Zoom (via CSS)
17 | - Mermaid Scale and Zoom (via CSS)
18 |
--------------------------------------------------------------------------------
/docs/gallery-cards/sync.ffs_db:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/gallery-cards/sync.ffs_db
--------------------------------------------------------------------------------
/docs/index.md:
--------------------------------------------------------------------------------
1 | ---
2 | nav_order: 1
3 | ---
4 |
5 | # Getting Started
6 | ## What is this snippet all about?
7 | Modular CSS Layout (MCL) snippets are meant to provide a useful layout options as a complement to the default theme or your chosen community theme. It focuses on working with Obsidian's CSS classes and HTML structure to achieve the intended layout; which also means it won't do any color-theme changes.
8 |
9 | > But I have to admit, compatibility with some theme (especially the more active and advanced ones might vary, but do log issues in my GH).
10 |
11 | ## How to get started?
12 | For the initiated, applying CSS snippets in Obsidian is quite a breeze. But the suggested approach in [Installation](https://efemkay.github.io/obsidian-modular-css-layout/installation/) gives you a few benefits
13 | - more user-friendly approach to download snippets
14 | - ease of updating whenever there's an update from the repo
15 |
16 | So far, there are three (3) modules for MCL snippets. Check out each module's documentation to know what are the available features and the corresponding CSS file
17 | - [Wide Views](https://efemkay.github.io/obsidian-modular-css-layout/wide-views/)
18 | - [Multi Column](https://efemkay.github.io/obsidian-modular-css-layout/multi-column/)
19 | - [Gallery Cards](https://efemkay.github.io/obsidian-modular-css-layout/gallery-cards/)
20 |
21 | > Note that the CSS snippets are meant to be modular. You don't have to install all of it.
22 | > I use the word install and installation loosely here, since they are just single `.css` file that you can just "Save As..." to your `[vault]/.obsidian/snippets` folder
23 |
24 |
25 | ## Support Me
26 | I do this on my free time for personal joy. However, a cup of coffee or two would motivate me further! If you like what I do, and want to contribute back, you can support me via Ko-fi
27 |
28 | [](https://ko-fi.com/M4M3C77PF)
29 |
--------------------------------------------------------------------------------
/docs/installation.md:
--------------------------------------------------------------------------------
1 | ---
2 | nav_order: 2
3 | ---
4 |
5 | # Installation
6 |
7 | This is actually just a CSS code snippets collection. So it isn't an installation per se, but rather **download and enable** in Obsidian.
8 |
9 | ### Using Snippet Downloader (recommended)
10 | Snippet Downloader is an Obsidian community plugin by Mara Li. Since I'm planning to update this snippets from time to time, this is the recommended approach as the plugin also provides a way to update/redownload from included repository
11 |
12 | {: .note-title }
13 | > Lisandra-dev Snippet Downloader plugin still can be used to install MCL (updated 27Aug2023)
14 | >
15 | > [Lisandra-dev](https://github.com/Lisandra-dev/obsidian-snippet-downloader) recently archived the plugin, but it is still very much functional for downloading snippets. There's additional step for you to install the plugin (since it's no longer available via Community Plugins) - it is reflected below...
16 |
17 | {: .warning }
18 | > Please ensure your vault's /.obsidian/snippets folder is already created before doing the following steps. You can do that by going to `Settings > Appearance` and click "Open snippets folder" under CSS snippets section
19 |
20 | 1. Install **Obsidian42 - BRAT** plugin and enable it
21 | - Go to `Settings > Community Plugins` and under **Community plugins** click **Browse** button
22 | - Search for `Obsidian42 - BRAT`, install it and enable it
23 | 2. Add Snippet Downloader plugin via BRAT
24 | - Open Command Palette (hotkey: `Ctrl/Cmd P`)
25 | - Search for `Obsidian 42 - BRAT: Plugins: Add a beta plugin for testing` and press `Enter`
26 | - Enter Snippet Downloader URL into the input box
27 | `https://github.com/Lisandra-dev/obsidian-snippet-downloader`
28 | - Enable Snippet Downloader by going back to `Settings > Community Plugins` and under **Installed Plugins** section toggle to ON the button next to Snippet Downloader
29 | 3. Ensure Obsidian snippets folder already created
30 | - Go to `Settings > Appearance`
31 | - Under **CSS snippets** section, click on the folder icon on the far right
32 | *this will create snippets folder inside your Obsidian vault (if you don't have one yet)*
33 | 4. Add MCL snippets (https://github.com/efemkay/obsidian-modular-css-layout) via Snippets Downloader
34 | - Open Command Palette (hotkey: `Ctrl/Cmd P`)
35 | - Search for `Snippet Downloader: Adding new snippet` and press `Enter`
36 | - Enter MCL GitHub URL into the input box
37 | `https://github.com/efemkay/obsidian-modular-css-layout`
38 | - Enable MCL snippets by going back to `Settings > Appearance` and under **CSS snippets** section (where you'll find the MCL snippets already downloaded into your vault)
39 |
40 |
41 | {: .note-title }
42 | > Example on how to install using Snippets Downloader
43 | >
44 | >
45 |
46 | ### Manually Saving from GH
47 |
48 | - Open your browser and go to MCL's GH [landing page](https://github.com/efemkay/obsidian-modular-css-layout)
49 | - Click on the snippet you want to save, (on the blob page) click on "Raw" at the top left, and (on the raw page) copy the entire text
50 | > *GH raw page will open up the css file within your browser in plain-text format for easy copy pasting*
51 | - Open any text editor in your desktop and paste the snippet
52 | - Save the file as a `.css` file into your `[vault]/.obsidian/snippets` folder. Filename can be anything.
53 | - Open Obisidian and go to `Settings > Appearance > CSS snippets` to enable the snippet.
54 | > *Click on "Reload snippets" button if the snippet does not appear in the list.*
55 |
--------------------------------------------------------------------------------
/docs/multi-column/02-multi-column-callout.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Multi Column Callout
3 | parent: Multi Column
4 | nav_order: 2
5 | ---
6 |
7 | # Multi Column Callout
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ## Overview
17 | Multi Column Callout layout take advantage of Obsidian Callout - leveraging it as parent 'div' to house the sub callout (including Dataview results block). You can nest as many sub-callouts within it
18 |
19 | The sub-callout will expand if `[!multi-column]` callout has extra space or overflow to next row if it doesn't. Some degree of control is available - see Additional Controls below
20 |
21 | 
22 |
23 | ### How to Use / Basic Syntax
24 | Here's a quick steps to create the Multi Column Callout. It's best to start with sub-callouts first to avoid getting confused on how to nest them.
25 | 1. Create the sub-callouts you want to include. In the example below they are `[!note]`, `[!warning]` and `[!summary]`
26 | 2. Wrap / encapsulate those sub-callouts with `[!multi-column]` callout
27 |
28 | Here's an example markdown
29 | ```
30 | > [!multi-column]
31 | >
32 | >> [!note]+ Work
33 | >> your notes or lists here. using markdown formatting
34 | >
35 | >> [!warning]+ Personal
36 | >> your notes or lists here. using markdown formatting
37 | >
38 | >> [!summary]+ Charity
39 | >> your notes or lists here. using markdown formatting
40 | ```
41 |
42 | > Note that when you insert callout within callout, the line separating the callouts should only use single angle bracket (">")
43 |
44 |
45 | {: .note-title }
46 | > What Counts as Column in a `[!multi-column]`?
47 | >
48 | > By default, another callout (aka sub-callout) within `[!multi-column]` is how you create a "column". But this snippets do provide a few alternatives
49 | > - immediate dataview block (either table or list)
50 | > - immediate blockquote
51 | > - ordered/unordered list (but need to have ` ` tag between lists due to how obsidian override "markdown loose list")
52 |
53 |
54 | ## Additional Controls
55 | ### Fixed Width Option for `[!multi-column]`
56 | This option will allow you to create fixed width multi column callout that doesn't expand. You can specify it to either align to the center, left or right. This may be useful if you want to create dashboard with icon that you want to stay clustered together rather than spread to fill in the space.
57 |
58 | To create a fixed-width multi column, use the following syntax:
59 | - `[!multi-column|center-fixed]` - for align to the center
60 | - `[!multi-column|left-fixed]` - for align to the left
61 | - `[!multi-column|right-fixed]` - for align to the right
62 |
63 | Here's an example markdown
64 | ```
65 | > [!multi-column|center-fixed]
66 | >
67 | >> [!blank-container]
68 | >> ![[icon 1.jpg]]
69 | >
70 | >> [!blank-container]
71 | >> ![[icon 2.jpg]]
72 | >
73 | >> [!blank-container]
74 | >> ![[icon 3.jpg]]
75 | ```
76 |
77 | ### No Wrap Option for `[!multi-column]`
78 | This option will allow you to create single row multi column callout. Horizontal scrollbar will appear when the sub-callouts exceed the width of the `[!multi-column]`. To create no wrap multi column, use the following syntax i.e. `[!multi-column|no-wrap]`.
79 |
80 | Here's an example markdown
81 | ```
82 | > [!multi-column|no-wrap]
83 | >
84 | >> [!note]+ Work
85 | >> your notes or lists here. using markdown formatting
86 | >
87 | >> [!warning]+ Personal
88 | >> your notes or lists here. using markdown formatting
89 | >
90 | >> [!summary]+ Charity
91 | >> your notes or lists here. using markdown formatting
92 | ```
93 |
94 | {: .note-title }
95 | > Limitation on No-Wrap Multi Column
96 | >
97 | > Width Control (different width for sub-callout) for now is not valid for No-Wrap Multi Column. Columns will be mostly follow the minimum width -- it has separate minimum width than the Wrapped Multi Column
98 |
99 | ### Width Control
100 | You can control sub-callout width by specifying the custom width option in the callout-metadata element (do NOT apply to `[!multi-column]` callout itself. So far, there's only a discrete options per below:
101 | - `min-0` - to override and disable min width set in Style Settings
102 | - `wide-2` - give callout twice the size
103 | - `wide-3` - three times the size
104 | - `wide-4` - four times the size
105 | - `wide-5` - five times the size
106 |
107 | Here's an example markdown
108 | ```
109 | > [!multi-column]
110 | >
111 | >> [!note|wide-3]+ Work
112 | >> your notes or lists here. using markdown formatting
113 | >
114 | >> [!warning|wide-2]+ Personal
115 | >> your notes or lists here. using markdown formatting
116 | >
117 | >> [!summary|min-0]+ Charity
118 | >> your notes or lists here. using markdown formatting
119 | ```
120 |
121 | {: .note-title }
122 | > When Pairing with sub-callout with min width
123 | >
124 | > By default, sub-callout within multi-column callout has min width of 200px (unless you changed it via Style Settings). Applying `wide-x` metadata for sub-callout that paired with those callout will have different sizing behaviour
125 |
126 | {: .note-title }
127 | > Understanding callout type and callout metadata
128 | >
129 | > - `> [!]` e.g. `> [!Summary]`
130 | > - `> [!|]` e.g. `> [!Summary|wide-2]`
131 |
132 | ### Additional Global Settings via Style Settings
133 | If you have Style Settings plugin installed, you may control the following aspects (go to `Style Settings > Modular CSS Layout - Multi Column > Multi Column Callout`)
134 | - Hide / Show SNW Indicator for images in Float Callout
135 | - Adjust minimum width for general sub-callout and No-Wrap sub-callout
136 | - Adjust gap between sub-callout and margin between sub-callout
137 |
138 | ## Examples
139 |
140 | #### Standard Multi-Column Callout
141 | > 
142 | > ```
143 | > > [!multi-column]
144 | > >
145 | > >> [!note]+ Use Case
146 | > >> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
147 | > >> ##### User Case Background
148 | > >> Vitae nunc sed velit dignissim sodales. In cursus turpis massa tincidunt dui ut ornare lectus.
149 | > >
150 | > >> [!warning]+ Resources
151 | > >> #### Requirement
152 | > >> - Lorem ipsum dolor sit amet
153 | > >> - Vitae nunc sed velit dignissim sodales.
154 | > >> - In cursus turpis massa tincidunt dui ut ornare lectus.
155 | > >
156 | > >> [!todo]+
157 | > >> - [x] Define Use Case
158 | > >> - [ ] Craft User Story
159 | > >> - [ ] Develop draft sketches
160 | > ```
161 |
162 | ---
163 |
164 | #### Icon Links Dashboard using Fixed Width option
165 | > 
166 | >
167 | > ```markdown
168 | > ## Icon Links Dashboard using `[!multi-column|center-fixed-small]`
169 | >
170 | > > [!multi-column|center-fixed-small]
171 | > >
172 | > >> [!blank|center]
173 | > >> [ Interests](target%20note.md)
174 | > >>
175 | > >> [ Technology](target%20note.md)
176 | > >
177 | > >> [!blank|center]
178 | > >> [ Life & Wisdom](target%20note.md)
179 | > >>
180 | > >> [ Work](target%20note.md)
181 | > >
182 | > >> [!blank|center]
183 | > >> [ Health](target%20note.md)
184 | > >>
185 | > >> [ Family](target%20note.md)
186 | >
187 | > ```
188 |
189 | ---
190 |
191 | #### Example Screenshot - Multi Column Callout with Width Control
192 |
193 |
194 | ---
195 |
196 | #### Example GIF - Install the snippet and apply Multi Column Callout
197 |
198 |
--------------------------------------------------------------------------------
/docs/multi-column/03-float-callout.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Float Callout
3 | parent: Multi Column
4 | nav_order: 3
5 | ---
6 |
7 | # Float Callout
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ## Overview
17 |
18 | Float Callout will allow you to position side note or info box either to the left or right of the main note with other content wrapping around it. It uses callout-metadata to specify which side to float to and the size of the callout
19 |
20 | > For this feature to work, please make sure your Obsidian **Installer** version is at v1.1.9 or higher as per screenshot below. Note that in Obsidian the "Current version: v1.x.x" is the App version while "(Installer version: v1.x.x)" is the **Installer** version I'm referring to above.
21 | >
22 | > 
23 |
24 | ### How To Use / Basic Syntax
25 |
26 | 1. Add `left` or `right` to the callout-metadata e.g. `[!info|right]`
27 | 2. Make sure the callout is above the paragraph that you want to have it wrapped around
28 |
29 | Here is an example markdown
30 |
31 | ```markdown
32 | ### Main Article
33 |
34 | > [!info|left]
35 | > Addition note to the main article
36 |
37 | Content of the main article
38 | ```
39 |
40 | > Basic syntax will apply to Reading View. To make it work with Live Preview see Additional Controls below
41 |
42 |
43 | ## Additional Controls
44 |
45 | ### Adjust Width Definition
46 |
47 | By default, the width of the callout will dynamically follow the content. You can make it fixed width by specifying the width option. There are 3 width option:
48 |
49 | - `-small` - default width 300px
50 | - `-medium` - default width 400px
51 | - `-large` - default width 600px
52 |
53 | Here's an example markdown
54 |
55 | ```markdown
56 | ## Main Article
57 |
58 | > [!info|left-medium]
59 | > Addition note to the main article
60 |
61 | Content of the main article
62 | ```
63 |
64 | ### Apply to Live Preview
65 |
66 | By default, if you only specify either left or right, Float Callout will only work in Reading View. If you want it to also work in Live Preview, prepend `float-` before the `left` or `right` e.g. `[!info|float-right]`
67 |
68 | Here's an example markdown
69 |
70 | ```markdown
71 | ## Main Article
72 |
73 | > [!info|float-left]
74 | > Addition note to the main article
75 |
76 | Content of the main article
77 | ```
78 |
79 | > **Note on Editing in Live Preview**
80 | >
81 | > In previous version of Float Image, editing text next to it was quite janky. I've improved it a bit (for `float-right` at least). For `float-left` you may still find selecting and navigating the text (up and down) still not possible.
82 | >
83 | > To edit, it's better to navigate using keyboard (from the top or bottom) instead of mouse/trackpad. Even better, use Source Mode to edit.
84 |
85 |
86 | ### Combining the Additional Controls
87 |
88 | You can also combine the above controls together. Here's an example markdown
89 |
90 | ```markdown
91 | ## Main Article
92 |
93 | > [!info|float-left-medium]
94 | > Addition note to the main article
95 |
96 | Content of the main article
97 | ```
98 |
99 | ### Additional Global Settings via Style Settings
100 |
101 | If you have Style Settings plugin installed, you may control the following aspects (go to `Style Settings > Modular CSS Layout - Multi Column > Float Callout`)
102 |
103 | - Hide / Show SNW Indicator in Float Callout
104 | - Adjust width definition for "small", "medium", and "large"
105 | - Adjust margin top for Float Callout
106 |
107 |
108 | ## Example
109 |
110 | #### Simple small callout float to the right
111 | > 
112 | > ```
113 | > ## When is the best to ski in Switzerland?
114 | > > [!info|float-right-small] Average Temperatures and Rainfall
115 | > > ![[Pasted image 20221105233818.png]]
116 | > >> Switzerland’s weather in January is dominated by cold temperatures and snowfall.
117 | >
118 | > - ### The best months to ski in Switzerland are December, January, and February with **January would be the best month** to ski in Switzerland of all three.
119 | > - Most tourists who intend to ski tend to visit **between Christmas and New Year**. Lots of locals go skiing during this period as well.
120 | > - **January** is the best month to ski in my opinion. Snow conditions are often good, there are fewer crowds and hotel prices are not as high.
121 | > - During **February**, it is common for locals to take ski vacations. If you go during this time, expect more crowds and higher hotel prices.
122 | >
123 | > ```
124 |
--------------------------------------------------------------------------------
/docs/multi-column/04-blank-callout.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Blank Callout
3 | parent: Multi Column
4 | nav_order: 4
5 | ---
6 |
7 | # Blank Callout
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ## Overview
17 |
18 | Blank Callout layout is just to provide an invisible container (or div). It is useful in many scenarios such as:
19 |
20 | - Creating floating picture with extensive caption
21 | - Creating side note without callout decoratives (like the background color and so on)
22 | - Invisible container for embedded images for a dashboard design
23 | - Invisible container to render things in Live Preview which normally need Reading View like List Columns/Grid/Card
24 |
25 | ### How To Use / Basic Syntax
26 |
27 | Insert a custom callout `[!blank-container]` or `[!blank]`. Here's an example markdown. Write your content within the callout (Obsidian automatically add `> ` when you press "Enter" key)
28 |
29 | ```markdown
30 | ## Header
31 |
32 | Main paragraph content
33 |
34 | > [!blank-container]
35 | > - list 1 #mcl/list-column
36 | > - list 2
37 | > - list 3
38 | > - list 4
39 |
40 | Next paragraph content
41 | ```
42 |
43 | > Sometimes, it may be easier to write the content first without the callout (because editing in callout is like editing in Obsidian Source Mode). Once you done with your content, select the entire text/block you want to include, `Ctrl/Cmd P` and select "Insert callout". Replace the callout type to `[!blank-container]` or `[!blank]`
44 |
45 | ## Additional Controls
46 |
47 | ### No Margin Option
48 |
49 | By default, Blank Callout still inherit the default margin and padding defined by Obsidian. To make it seamless with the note (in term of alignment, especially when doing List Column/Grid/Card for Live Preview) you can specify the `no-margin` option in the callout-metadata i.e. `[!blank-container|no-margin]`
50 |
51 | Here's an example markdown
52 |
53 | ```markdown
54 | ## Header
55 |
56 | Main paragraph content
57 |
58 | > [!blank-container|no-margin]
59 | > - list 1 #mcl/list-column
60 | > - list 2
61 | > - list 3
62 | > - list 4
63 |
64 | Next paragraph content
65 | ```
66 |
--------------------------------------------------------------------------------
/docs/multi-column/05-list-column.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: List Column
3 | parent: Multi Column
4 | nav_order: 5
5 | ---
6 |
7 | # List Column
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ## Overview
17 | List Column layout will allow you to create multi column layout using unordered lists (i.e. `- list item`). There are 3 different ways you can do so using MCL snippets i.e.
18 | 1. Apply at the specific list block using hashtag. This is the recommended option.
19 | 2. Apply at the specific list block using Markdown Attributes plugin.
20 | 3. Apply at the frontmatter. This affects ALL unordered list in that particular note
21 |
22 | 
23 |
24 | {: .note-title }
25 | > Making it work in Live Preview
26 | >
27 | > The column layout will only work on Reading View. If you want to make it work on Live Preview, there are a few options. You can encapsulate the list block in MCL's `[blank-container]` callout
28 |
29 | ### Using hashtag i.e. `#mcl/list-column`
30 | - This option require your Obsidian to be installed with installer version 1.1.9 or higher (note that there are installer and app versions).
31 | - Place the tag anywhere in the top-level list items (preferably in the first bullet for easy identification). If you have consecutive group of list that you actually meant to be a separate lists, ensure to properly "break" it by placing either a header, horizontal line or ` ` tag in between
32 |
33 | Here's an example markdown:
34 |
35 | ```md
36 | - list item 1 #mcl/list-column
37 | - list item 2
38 | - list item 3
39 | - sub list 3-1
40 | - sub list 3-2
41 | - list item 4
42 | - list item 5
43 | - sub list 5-1
44 | - list item 6
45 | ```
46 |
47 | > Using this option, the number of columns or grids or cards is determined by minimum width (adjustable using Style Settings plugin), available note/page width and how many bullets. Under default settings, normal page layout can fit 3 columns/grids/cards but if there's only two bullets, it will expand to fill the space.
48 |
49 | ### Using Markdown Attributes plugin
50 | Using this approach will require [Markdown Attributes](https://github.com/valentine195/obsidian-markdown-attributes) plugin. Read the plugin documentation where to put the CSS class (typically at the end of the block). MCL provides the following CSS classes
51 | - `{.two-column-list-block}`
52 | - `{.three-column-list-block}`
53 | - `{.four-column-list-block}`
54 | - `{.multi-column-list-block}` - number of columns depend of note's width and MCL settings on minimum width (default is 200px)
55 |
56 | For this approach, do note that there's a dot (`.`) before the class name. This is following how CSS classes are referred in CSS file.
57 |
58 | Here's an example markdown:
59 | ```md
60 | ---
61 | cssClass: two-column-list
62 | ---
63 |
64 | - list item 1 #mcl/list-column
65 | - list item 2
66 | - list item 3
67 | - sub list 3-1
68 | - sub list 3-2
69 | - list item 4
70 | - list item 5
71 | - sub list 5-1
72 | - list item 6
73 | { .two-column-list-block }
74 | ```
75 |
76 | > By default, there's a column ruler (vertical guide line). You may disable it via Style Settings
77 |
78 | > Note that this approach do not work well if the last bullet is indented (not part of top level list). Example here
79 | > ```md
80 | > ---
81 | > cssClass: two-column-list
82 | > ---
83 | >
84 | > - list item 1 #mcl/list-column
85 | > - list item 2
86 | > - list item 3
87 | > - sub list 3-1
88 | > - sub list 3-2
89 | > { .two-column-list-block }
90 | > ```
91 |
92 | ### Using frontmatter declaration
93 | Using this approach, you will have to specify the css for the column type at the frontmatter (it must be located at the very top of your document, wrapped by two sets of 3 dashes i.e. `---`, see example below for better understanding). MCL provides the following CSS classes
94 | - `two-column-list`
95 | - `three-column-list`
96 | - `four-column-list`
97 | - `multi-column-list`
98 |
99 | Here's an example markdown:
100 | ```md
101 | ---
102 | cssClass: two-column-list
103 | ---
104 |
105 | - list item 1 #mcl/list-column
106 | - list item 2
107 | - list item 3
108 | - sub list 3-1
109 | - sub list 3-2
110 | - list item 4
111 | - list item 5
112 | - sub list 5-1
113 | - list item 6
114 | ```
115 |
116 | ## Example
117 | 
118 |
119 | ---
120 |
121 |
122 |
--------------------------------------------------------------------------------
/docs/multi-column/06-list-grid.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: List Grid
3 | parent: Multi Column
4 | nav_order: 6
5 | ---
6 |
7 | # List Grid
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ## Overview
17 | List Grid layout will allow you to create multi column and multi row layout using a combinatio of (a) unordered lists (i.e. `- list item`) and (b) either hashtag or css class at frontmatter. There are 3 different ways you can do so using MCL snippets i.e.
18 | 1. Apply at the specific list block using hashtag. This is the recommended option.
19 | 2. Apply at the frontmatter. This affects ALL unordered list in that particular note
20 |
21 | 
22 |
23 | {: .note-title }
24 | > Making it work in Live Preview
25 | >
26 | > The column layout will only work on Reading View. If you want to make it work on Live Preview, there are a few options. You can encapsulate the list block in MCL's `[blank-container]` callout
27 | >
28 | > ...
29 | >
30 | > **There's no Markdown Attributes plugin approach**
31 | >
32 | > There are no Markdown Attributes approach due to limitation in specifying at the end of list block
33 |
34 |
35 | ### How To - Using hashtag i.e. `#mcl/list-grid`
36 | Technically List Card is quite similar to List Grid but with extra customisation to make it card like. In order to enable it, place the hashtag anywhere in the top-level list items (preferably in the first bullet for easy identification). There are two options for List Card i.e.
37 | - `#mcl/list-grid` - default minimum width 250px
38 | - `#mcl/list-grid-wide` - default minimum width 350px
39 |
40 | If you have consecutive group of list that you actually meant to be a separate lists, ensure to properly "break" it by placing either a header, horizontal line or ` ` tag in between
41 |
42 | > This option require your Obsidian to be installed with installer version 1.1.9 or higher (note that there are installer and app versions).
43 |
44 | Here's an example markdown:
45 | ```md
46 | - #### Core Work #mcl/list-grid
47 | - [[00 Home|Main Goal 1]]
48 | - [[00 Home|Main Goal 1]]
49 | - [[00 Home|Main Goal 1]]
50 | - Collaboration with Jane
51 | - [[00 Home|Main Goal 1]]
52 | - #### Learning & System
53 | - [[00 Home|Learning Goal 1]]
54 | - [[00 Home|Initiative 1]]
55 | - [[00 Home|Initiative 2]]
56 | - #### Personal
57 | - [[00 Home|Personal Goal 1]]
58 | - [[00 Home|Personal Goal 2]]
59 | ```
60 |
61 | > The number of cards can appear per row is subject to card's minimum width and note's width. Card's minimum width is adjustable via Style Settings plugin.
62 |
63 |
64 | ### How To - Using frontmatter declaration
65 | Using this approach, you will have to specify the css for the column type at the frontmatter (it must be located at the very top of your document, wrapped by two sets of 3 dashes i.e. `---`, see example below for better understanding). MCL provides the following CSS classes
66 | - `two-column-grid-list`
67 | - `three-column-grid-list`
68 |
69 | Here's an example markdown:
70 | ```md
71 | ---
72 | cssClass: two-column-grid-list
73 | ---
74 |
75 | - #### Core Work
76 | - [[00 Home|Main Goal 1]]
77 | - [[00 Home|Main Goal 1]]
78 | - [[00 Home|Main Goal 1]]
79 | - Collaboration with Jane
80 | - [[00 Home|Main Goal 1]]
81 | - #### Learning & System
82 | - [[00 Home|Learning Goal 1]]
83 | - [[00 Home|Initiative 1]]
84 | - [[00 Home|Initiative 2]]
85 | - #### Personal
86 | - [[00 Home|Personal Goal 1]]
87 | - [[00 Home|Personal Goal 2]]
88 | ```
89 |
90 |
91 | ## Additional Controls
92 | If you have Style Settings plugin installed, you may control the following aspects (go to `Style Settings > Modular CSS Layout - Multi Column > List Grid and List Card`)
93 | - Card's width and background Color
94 | - Cards' border width and border color
95 | - Gap between card
96 | - Bottom border for the first header in the card
97 |
98 | ## Example
99 | 
100 |
--------------------------------------------------------------------------------
/docs/multi-column/07-list-card.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: List Card
3 | parent: Multi Column
4 | nav_order: 7
5 | ---
6 |
7 | # List Card
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ## Overview
17 |
18 | List Card layout will allow you to create multi column and multi row layout using a combination of (a) unordered lists (i.e. `- list item`) and (b) custom hashtag at the specific list block.
19 |
20 | 
21 |
22 | {: .note-title }
23 | > Making it work in Live Preview
24 | >
25 | > The column layout will only work on Reading View. If you want to make it work on Live Preview, there are a few options. You can encapsulate the list block in MCL's `[blank-container]` callout
26 | >
27 | > ...
28 | >
29 | > **There's no Markdown Attributes plugin approach**
30 | >
31 | > There are no Markdown Attributes approach due to limitation in specifying at the end of list block
32 |
33 |
34 | ### How to Use `#mcl/list-card`
35 |
36 | Technically List Card is quite similar to List Grid but with extra customisation to make it card like. In order to enable it, place the hashtag anywhere in the top-level list items (preferably in the first bullet for easy identification). There are two options for List Card i.e.
37 | - `#mcl/list-card` - default minimum width 250px
38 | - `#mcl/list-card-wide` - default minimum width 350px
39 |
40 | If you have consecutive group of list that you actually meant to be a separate lists, ensure to properly "break" it by placing either a header, horizontal line or ` ` tag in between
41 |
42 | > This option require your Obsidian to be installed with installer version 1.1.9 or higher (note that there are installer and app versions).
43 |
44 | Here's an example markdown:
45 | ```md
46 | - #### Core Work #mcl/list-card
47 | - [[00 Home|Main Goal 1]]
48 | - [[00 Home|Main Goal 1]]
49 | - [[00 Home|Main Goal 1]]
50 | - Collaboration with Jane
51 | - [[00 Home|Main Goal 1]]
52 | - #### Learning & System
53 | - [[00 Home|Learning Goal 1]]
54 | - [[00 Home|Initiative 1]]
55 | - [[00 Home|Initiative 2]]
56 | - #### Personal
57 | - [[00 Home|Personal Goal 1]]
58 | - [[00 Home|Personal Goal 2]]
59 | ```
60 |
61 | > The number of cards can appear per row is subject to card's minimum width and note's width. Card's minimum width is adjustable via Style Settings plugin.
62 |
63 | {: .note-title }
64 | > List Card applies only to first level bullet
65 | >
66 | > Due to some constraints, current implementation of List Card applies to first level bullet despite declaring the hashtag in the sub bullet.
67 |
68 |
69 | ## Additional Controls
70 | If you have Style Settings plugin installed, you may control the following aspects (go to `Style Settings > Modular CSS Layout - Multi Column > List Grid and List Card`)
71 | - Card's width and background Color
72 | - Cards' border width and border color
73 | - Gap between card
74 | - Bottom border for the first header in the card
75 |
76 | ## Example
77 | 
78 |
--------------------------------------------------------------------------------
/docs/multi-column/index.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Multi Column
3 | nav_order: 4
4 | has_children: true
5 | ---
6 |
7 | # Multi Column
8 |
9 | > CSS snippet file: [MCL Multi Column.css](https://github.com/efemkay/obsidian-modular-css-layout/blob/main/MCL%20Multi%20Column.css)
10 |
11 | This snippet will allow you to re-shape the either callout or (unordered) list and position them side by side. See each subsection for more details on how to control that. In summary this snippet has the following features
12 |
13 | - Multi column layout using custom callout `[!multi-column]`
14 | - to be used with sub callout or codeblocks
15 | - Invisible container using custom callout `[!blank-container]`
16 | - to be used as grouping container like a dashboard
17 | - Multi column bullet list at (a) note level, and (b) block level
18 | - Side/Floating column using callout-metadata ``
19 | - use `[!|-]` to affect only Reading View or `[!|float--]` to also apply in Live Preview.
20 |
21 |
22 |
23 | > For this features to work, please make sure your Obsidian **Installer** version is at v1.1.9 or higher as per screenshot below. Note that in Obsidian the "Current version: v1.x.x" is the App version while "(Installer version: v1.x.x)" is the **Installer** version I'm referring to above.
24 | >
25 | > 
26 |
--------------------------------------------------------------------------------
/docs/multi-column/old-02a-mc-callout-examples.md:
--------------------------------------------------------------------------------
1 |
2 |
3 | ### Standard Multi-Column Callout
4 | > 
5 | > ```
6 | > > [!multi-column]
7 | > >
8 | > >> [!note]+ Use Case
9 | > >> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
10 | > >> ##### User Case Background
11 | > >> Vitae nunc sed velit dignissim sodales. In cursus turpis massa tincidunt dui ut ornare lectus.
12 | > >
13 | > >> [!warning]+ Resources
14 | > >> #### Requirement
15 | > >> - Lorem ipsum dolor sit amet
16 | > >> - Vitae nunc sed velit dignissim sodales.
17 | > >> - In cursus turpis massa tincidunt dui ut ornare lectus.
18 | > >
19 | > >> [!todo]+
20 | > >> - [x] Define Use Case
21 | > >> - [ ] Craft User Story
22 | > >> - [ ] Develop draft sketches
23 | > ```
24 |
25 | ---
26 |
27 | ### Icon Links Dashboard using Fixed Width option
28 | > 
29 | >
30 | > ```markdown
31 | > ## Icon Links Dashboard using `[!multi-column|center-fixed-small]`
32 | >
33 | > > [!multi-column|center-fixed-small]
34 | > >
35 | > >> [!blank|center]
36 | > >> [ Interests](target%20note.md)
37 | > >>
38 | > >> [ Technology](target%20note.md)
39 | > >
40 | > >> [!blank|center]
41 | > >> [ Life & Wisdom](target%20note.md)
42 | > >>
43 | > >> [ Work](target%20note.md)
44 | > >
45 | > >> [!blank|center]
46 | > >> [ Health](target%20note.md)
47 | > >>
48 | > >> [ Family](target%20note.md)
49 | >
50 | > ```
51 |
52 | ---
53 |
54 | ### Example Screenshot - Multi Column Callout with Width Control
55 |
56 |
57 | ---
58 |
59 | ### Using Multi-Column Callout within another Multi-Column Callout
60 |
61 | 
62 |
63 | ```
64 | > [!multi-column]
65 | >
66 | > > [!blank|no-margin pw2]
67 | > > Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
68 | >
69 | > > [!multi-column|pw6]
70 | > >
71 | > > > [!tldr]- Manifest
72 | > > > Contents
73 | > >
74 | > > > [!info]- Backlog
75 | > > > Contents
76 | > >
77 | > > > [!tip] Project
78 | > > > - ### Project A
79 | > > > - completed
80 | > > > - ### Project B
81 | > > > - ongoing
82 | ```
83 |
84 | - It will be easier if we think how to build this logically. Remember, in the above example, the main `[!multi-column]` contains two children i.e. `[!blank|no-margin pw2]` and `[!multi-column|pw6]`.
85 | - The second (or nested `[!multi-column|pw6]`) then contains three (3) sub-callouts i.e. `[!tldr]- Manifest`, `[!info]- Backlog` and `[!tip] Project`
86 |
87 | {: .note-title }
88 | > Sub-callout hierarchy for example above
89 | >
90 | > - `[!multi-column]`
91 | > 1. `[!blank|no-margin pw2]`
92 | > 2. `[!multi-column|pw6]`
93 | > 1. `[!tldr]- Manifest`
94 | > 2. `[!info]- Backlog`
95 | > 3. `[!tip] Project`
96 |
97 |
98 | ---
99 |
100 | ### Example GIF - Install the snippet and apply Multi Column Callout
101 |
102 |
--------------------------------------------------------------------------------
/docs/multi-column/sync.ffs_db:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/docs/multi-column/sync.ffs_db
--------------------------------------------------------------------------------
/docs/showcases/float-with-mc-dataview.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Float with MC Dataview
3 | parent: Showcases
4 | nav_order: 2
5 | ---
6 |
7 | #### Screenshot
8 |
9 | 
10 |
11 | #### Raw Markdown
12 |
13 | ```md
14 | ---
15 | cssclass: text-justify, wide-page, minimal-float
16 | ---
17 |
18 | ## General linear model
19 |
20 | > [!blank-container|right-medium] Relationship of Data, Information and Intelligence
21 | > ![[Pasted image 20220424085124.png]]
22 | > Example of [simple linear regression](https://en.wikipedia.org/wiki/Simple_linear_regression "Simple linear regression"), which has one independent variable
23 |
24 | The **general linear model** or **general multivariate regression model** is a compact way of simultaneously writing several [multiple linear regression](https://en.wikipedia.org/wiki/Multiple_linear_regression "Multiple linear regression") models. In that sense it is not a separate statistical [linear model](https://en.wikipedia.org/wiki/Linear_model "Linear model"). The various multiple linear regression models may be compactly written as $Y=XB + U$
25 |
26 | The general linear model incorporates a number of different statistical models: ANOVA, ANCOVA, MANOVA, MANCOVA, ordinary linear regression, _t_-test and _F_-test. The general linear model is a generalization of multiple linear regression to the case of more than one dependent variable. If **Y**, **B**, and **U** were column vectors, the matrix equation above would represent multiple linear regression.
27 |
28 | Hypothesis tests with the general linear model can be made in two ways: multivariate or as several independent univariate tests. In multivariate tests the columns of **Y** are tested together, whereas in univariate tests the columns of **Y** are tested independently, i.e., as multiple univariate tests with the same design matrix.
29 |
30 | ## Other Notes on Regression Model
31 | > [!multi-column]
32 | >
33 | > ```dataview
34 | > table without id file.link as "Statistical Analysis"
35 | > from "sample data A"
36 | > ```
37 | >
38 | > ```dataview
39 | > table without id file.link as "Regression"
40 | > from "sample data B"
41 | > ```
42 | >
43 | > ```dataview
44 | > table without id file.link as "Model Validation"
45 | > from "sample data C"
46 | > ```
47 |
48 | > sample text extracted from [General linear model - Wikipedia](https://en.wikipedia.org/wiki/General_linear_model) and [Linear regression - Wikipedia](https://en.wikipedia.org/wiki/Linear_regression#Simple_and_multiple_linear_regression)
49 | ---
50 | ```
51 |
--------------------------------------------------------------------------------
/docs/showcases/index.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Showcases
3 | nav_order: 6
4 | has_children: true
5 | ---
6 |
7 | # MCL Showcases
8 |
9 | Examples and showcases on how to make full use of MCL snippets in your Obsidian vault. Take note on the required settings and additional plugin (if any) to recreate the similar looks.
10 | {: .fs-6 .fw-300 }
11 |
--------------------------------------------------------------------------------
/docs/showcases/mc-callout-and-list.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: MC Callout and List
3 | parent: Showcases
4 | nav_order: 3
5 | ---
6 |
7 | #### Screenshot
8 |
9 | 
10 |
11 | #### Raw Markdown
12 |
13 | ```md
14 | ---
15 | cssclass: wide-page
16 | ---
17 |
18 | > [!multi-column]
19 | > > [!Todo]+ Deliverables Milestone
20 | > > - [x] Insider's Alpha Release
21 | > > - [ ] Gold & Silver Supporters Meetup
22 | > > - [ ] Public Beta Release
23 | >
24 | > > [!Summary]+ Funding Milestone
25 | > > - Series A: $ 1.1 mil
26 | > > - Series B: ongoing
27 | > > - Series C: planned
28 |
29 | ## Project Background
30 | Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Interdum velit euismod in pellentesque massa placerat duis. Bibendum arcu vitae elementum curabitur vitae nunc. Quis ipsum suspendisse ultrices gravida. Risus in hendrerit gravida rutrum quisque non tellus.
31 |
32 | #### Use Case
33 | Viverra mauris in aliquam sem fringilla ut morbi tincidunt. Faucibus pulvinar elementum integer enim neque volutpat ac tincidunt vitae. Urna et pharetra pharetra massa massa ultricies. Ultrices eros in cursus turpis massa tincidunt. Ullamcorper velit sed ullamcorper morbi. Ornare quam viverra orci sagittis eu. Tortor dignissim convallis aenean et tortor at.
34 | - Consectetur adipiscing elit ut aliquam purus sit amet luctus.
35 | - Est lorem ipsum dolor sit. Blandit cursus risus at ultrices mi.
36 | - Vestibulum mattis ullamcorper velit sed ullamcorper. In mollis nunc sed id semper risus in.
37 | {.two-column-list-block}
38 |
39 | ## Supporters
40 | - **Nina** (Gold)
41 | - **Frankie** (Silver)
42 | - **Nurul** (Silver)
43 | - **Kamala** (Silver)
44 | - Nguyen
45 | - Cypher
46 | - Powell
47 | - Sam
48 | - Kate
49 | - Roger
50 | - Sharon
51 | - Peter
52 | - Obadiah
53 | - Serena
54 | - Nicholas
55 | {.multi-column-list-block}
56 |
57 | ```
58 |
--------------------------------------------------------------------------------
/docs/showcases/mc-callout-list-card.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: MC Callout and List Card
3 | parent: Showcases
4 | ---
5 |
6 | #### Screenshot
7 |
8 | 
9 |
10 | #### Raw Markdown
11 |
12 | ```md
13 | ---
14 | cssClass: minimal-float, wide-page
15 | ---
16 |
17 | > #### What do you need to achieve this?
18 | > - MCL's Multi Column snippet
19 | > - using callout `[!multi-column]`, and `[!blank]` and tag `#mcl/list-card`
20 | > - List Card width set to 200px (via Style Settings)
21 | > - Contextual Typography plugin
22 | > - so that the css can target the right list
23 |
24 | ## When is the best to ski in Switzerland?
25 |
26 | > [!multi-column]
27 | >
28 | > > [!blank|wide-3]
29 | > > - ### **The best months to ski** in Switzerland are **December, January, and February** with **January would be the best month to ski in Switzerland** of all three.
30 | > > - Most tourists who intend to ski tend to visit **between Christmas and New Year**. Lots of locals go skiing during this period as well.
31 | > > - **January** is the best month to ski in my opinion. Snow conditions are often good, there are fewer crowds and hotel prices are not as high.
32 | > > - During **February**, it is common for locals to take ski vacations. If you go during this time, expect more crowds and higher hotel prices.
33 | >
34 | > > [!info|wide-2]
35 | > > ![[Pasted image 20221105233818.png]]
36 | > > > Switzerland’s weather in January is dominated by cold temperatures and snowfall.
37 |
38 |
39 | ## Potential Beginner-Friendly Ski Resorts
40 | - ### Arosa #mcl/list-card
41 | - 
42 | - Down the road from the famous [St Moritz](https://www.skisolutions.com/ski-holidays/switzerland-resorts/st-moritz) ski resort, [Arosa](https://www.skisolutions.com/ski-holidays/switzerland-resorts/arosa) has a lot to offer for beginners. There are nursery slopes and kids areas for first-time skiers to learn near the village.
43 | - The Swiss ski resort attracts just as many non-skiers as skiers, because of its easy access and the beautiful town. It has a mixture of understated luxury, local traditions, and fantastic skiing.
44 | - [View Arosa ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/arosa)
45 | - #### Transfer Time
46 | - Geneva 4h 0m
47 | - ### Crans Montana
48 | - 
49 | - The amount of beginner ski areas and 55km of blue runs in [Crans Montana](https://www.skisolutions.com/ski-holidays/switzerland-resorts/crans-montana) is a welcoming combination for first-time skiers. It’s one of the rare resorts where you can see the iconic Mont Blanc and Matterhorn mountains whilst you’re skiing.
50 | - If you’re a foodie you’re in for a treat as there are over 90 restaurants in the village and mountains.
51 | - [View Crans Montana resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/crans-montana)
52 | - #### Transfer Time
53 | - From Zurich 3h 30m
54 | - From Geneva 2h 0m
55 | - ### Davos
56 | - 
57 | - On and off the slopes, [Davos](https://www.skisolutions.com/ski-holidays/switzerland-resorts/davos) is an easy ride and a great place to relax. Beginners can start on the nursery slopes at the foot of the Jakobshorn.
58 | - The small town still has a traditional alpine charm but offers fantastic luxury options. You can also admire the fantastic mountain views that surround the ski resort.
59 | - [View Davos ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/davos)
60 | - #### Davos Transfer time
61 | - Geneva 4h 50m
62 | - Zurich 2h 45m
63 | - ### Grindelwald
64 | - 
65 | - The Bodmia beginners area in [Grindelwald](https://www.skisolutions.com/ski-holidays/switzerland-resorts/grindelwald) is an ideal place to learn, located in the [Jungfrau](https://www.skisolutions.com/blog/jungfrau-ski-area) region. The village is a picturesque mountain town with luxury ski options. You can even ride the mountain railway for a day to visit neighbouring mountain towns.
66 | - The [bodmiARENA](https://www.grindelwaldsports.ch/en/bodmiarena.html) is a special beginners' zone.
67 | - [View Grindelwald ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/grindelwald)
68 | - #### Transfer time
69 | - Zurich 2h 0m
70 | - Geneva 2h 30m
71 | - ### Nendaz
72 | - 
73 | - There has been a recent investment in the beginner’s area in [Nendaz](https://www.skisolutions.com/ski-holidays/switzerland-resorts/nendaz). This area is located at the top of the Tracout bubble and is a fantastic place to learn.
74 | - There are new drag lifts and magic carpets on the wide easy slopes. Part of the [4 Valleys ski area](https://www.skisolutions.com/blog/four-valleys-ski-area), Nendaz is the more affordable resort compared to neighbouring [Verbier](https://www.skisolutions.com/ski-holidays/switzerland-resorts/verbier).
75 | - [View Nendaz ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/nendaz)
76 | - Transfer Time
77 | - From Geneva 1h 40m
78 | - ### Zermatt
79 | - 
80 | - What’s better than learning how to ski under the iconic view of the Matterhorn mountain? [Zermatt](https://www.skisolutions.com/ski-holidays/switzerland-resorts/zermatt) has a state-of-the-art beginner park in the Sunnegga area, perfect for first-time skiers and children.
81 | - When you’re off the slopes, there’s fantastic restaurants and bars to visit in the village. A ski resort that will give you the ski bug for sure.
82 | - [View Zermatt ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/zermatt)
83 |
84 |
85 | ---
86 | > alternate method -- nest the list with `#mcl/list-card` inside a `[!blank]` callout
87 |
88 | > [!blank]
89 | >
90 | > - ### Arosa #mcl/list-card
91 | > - 
92 | > - Down the road from the famous [St Moritz](https://www.skisolutions.com/ski-holidays/switzerland-resorts/st-moritz) ski resort, [Arosa](https://www.skisolutions.com/ski-holidays/switzerland-resorts/arosa) has a lot to offer for beginners. There are nursery slopes and kids areas for first-time skiers to learn near the village.
93 | > - The Swiss ski resort attracts just as many non-skiers as skiers, because of its easy access and the beautiful town. It has a mixture of understated luxury, local traditions, and fantastic skiing.
94 | > - [View Arosa ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/arosa)
95 | > - #### Transfer Time
96 | > - Geneva 4h 0m
97 | > - ### Crans Montana
98 | > - 
99 | > - The amount of beginner ski areas and 55km of blue runs in [Crans Montana](https://www.skisolutions.com/ski-holidays/switzerland-resorts/crans-montana) is a welcoming combination for first-time skiers. It’s one of the rare resorts where you can see the iconic Mont Blanc and Matterhorn mountains whilst you’re skiing.
100 | > - If you’re a foodie you’re in for a treat as there are over 90 restaurants in the village and mountains.
101 | > - [View Crans Montana resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/crans-montana)
102 | > - #### Transfer Time
103 | > - From Zurich 3h 30m
104 | > - From Geneva 2h 0m
105 | > - ### Davos
106 | > - 
107 | > - On and off the slopes, [Davos](https://www.skisolutions.com/ski-holidays/switzerland-resorts/davos) is an easy ride and a great place to relax. Beginners can start on the nursery slopes at the foot of the Jakobshorn.
108 | > - The small town still has a traditional alpine charm but offers fantastic luxury options. You can also admire the fantastic mountain views that surround the ski resort.
109 | > - [View Davos ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/davos)
110 | > - #### Davos Transfer time
111 | > - Geneva 4h 50m
112 | > - Zurich 2h 45m
113 | > - ### Grindelwald
114 | > - 
115 | > - The Bodmia beginners area in [Grindelwald](https://www.skisolutions.com/ski-holidays/switzerland-resorts/grindelwald) is an ideal place to learn, located in the [Jungfrau](https://www.skisolutions.com/blog/jungfrau-ski-area) region. The village is a picturesque mountain town with luxury ski options. You can even ride the mountain railway for a day to visit neighbouring mountain towns.
116 | > - The [bodmiARENA](https://www.grindelwaldsports.ch/en/bodmiarena.html) is a special beginners' zone.
117 | > - [View Grindelwald ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/grindelwald)
118 | > - #### Transfer time
119 | > - Zurich 2h 0m
120 | > - Geneva 2h 30m
121 | > - ### Nendaz
122 | > - 
123 | > - There has been a recent investment in the beginner’s area in [Nendaz](https://www.skisolutions.com/ski-holidays/switzerland-resorts/nendaz). This area is located at the top of the Tracout bubble and is a fantastic place to learn.
124 | > - There are new drag lifts and magic carpets on the wide easy slopes. Part of the [4 Valleys ski area](https://www.skisolutions.com/blog/four-valleys-ski-area), Nendaz is the more affordable resort compared to neighbouring [Verbier](https://www.skisolutions.com/ski-holidays/switzerland-resorts/verbier).
125 | > - [View Nendaz ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/nendaz)
126 | > - Transfer Time
127 | > - From Geneva 1h 40m
128 | > - ### Zermatt
129 | > - 
130 | > - What’s better than learning how to ski under the iconic view of the Matterhorn mountain? [Zermatt](https://www.skisolutions.com/ski-holidays/switzerland-resorts/zermatt) has a state-of-the-art beginner park in the Sunnegga area, perfect for first-time skiers and children.
131 | > - When you’re off the slopes, there’s fantastic restaurants and bars to visit in the village. A ski resort that will give you the ski bug for sure.
132 | > - [View Zermatt ski resort here](https://www.skisolutions.com/ski-holidays/switzerland-resorts/zermatt)
133 | ```
134 |
--------------------------------------------------------------------------------
/docs/wide-views/index.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Wide Views
3 | nav_order: 3
4 | has_children: true
5 | ---
6 |
7 | # Wide Views
8 | {: .no_toc }
9 |
10 | ## Table of Contents
11 | {: .no_toc .text-delta }
12 |
13 | 1. TOC
14 | {:toc}
15 |
16 | ---
17 |
18 | ## Understanding the snippet
19 | - CSS snippet file: [MCL Wide Views.css](https://github.com/efemkay/obsidian-modular-css-layout/blob/main/MCL%20Wide%20Views.css)
20 | - This snippet will provide the following features
21 | - Wide views using YAML `cssClass: wide-` for applying to a specific individual note
22 | - Wide views using vault-wide toggle for applying to all notes in your vault
23 | - will require Style Settings plugin to enable the feature
24 |
25 | ---
26 |
27 | ## Using YAML (specifying `cssClass`)
28 |
29 | - CSS snippet: `MCL Wide Views.css`
30 | - Custom CSS class available
31 | - `wide-page`
32 | - `wide-dataview`
33 | - `wide-table`
34 | - `wide-backlinks`
35 |
36 | This snippet allow you to use Obsidian CSS class helper to enable any of the wide views. To use it, add the helper class in the YAML (frontmatter) of your note (which must be at the top of the note) like below.
37 |
38 | ```markdown
39 | ---
40 | cssClass: wide-page
41 | ---
42 |
43 |
44 | ```
45 |
46 | {: .note }
47 | > Thanks to Obsidian updated Electron base to V21, I have managed to avoid using Contextual Typography plugin to support wide blocks with the release of [v0.9.6](https://github.com/efemkay/obsidian-modular-css-layout/releases/tag/0.9.6)
48 |
49 | ## Example
50 |
51 |
52 |
53 | ---
54 |
55 | ## Using Style Settings toggle (affecting vault wide)
56 |
--------------------------------------------------------------------------------
/docs/wide-views/wvsettings.md:
--------------------------------------------------------------------------------
1 | ---
2 | title: Wide Views Settings
3 | parent: Wide Views
4 | nav_order: 3
5 | ---
6 |
7 | # Style Settings
8 |
9 | ## Adjustable RLL Settings
10 |
11 | ### Enable Adjustable RLL
12 | Switch to enable you to adjust the RLL width (Obisidan default is 700px). Set the width using setting below.
13 |
14 | ### Max Width for Normal Width page
15 | Set the max width for normal-width page. Enable Adjustable RLL option above must be "On" for this to take effect.
16 |
17 | ## Wide Page Settings
18 |
19 | ### Max Width for Normal Width block
20 | Set the max width for normal-width blocks for page/note that you specify with `cssClass: wide-`
21 |
22 | ## Narrow Page Settings
23 |
24 | ### Max Width for Narrow View page
25 | Set the max width for the page/note that you specify with `cssClass: narrow-page`.
26 |
27 | ---
28 |
29 |
30 |
--------------------------------------------------------------------------------
/screenshots/mcl-callout-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/screenshots/mcl-callout-example.png
--------------------------------------------------------------------------------
/screenshots/mcl-list-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/screenshots/mcl-list-example.png
--------------------------------------------------------------------------------
/screenshots/mcl-wideviews-example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/screenshots/mcl-wideviews-example.png
--------------------------------------------------------------------------------
/screenshots/multi-column-showcase.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/efemkay/obsidian-modular-css-layout/1db5920dfb5d557570aac37a5e368b82613daef7/screenshots/multi-column-showcase.png
--------------------------------------------------------------------------------