From f5f542777febe6a2a4463bb8042e9a72e628e724 Mon Sep 17 00:00:00 2001 From: Ashelyn Rose Date: Sat, 22 Mar 2025 18:02:52 -0600 Subject: Fonts --- Cargo.toml | 2 +- global.scss | 13 ---- public/fonts/DraftingMono-ExtraLight.woff2 | Bin 0 -> 27616 bytes public/fonts/Quicksand-Regular.ttf | Bin 0 -> 78932 bytes readme.md | 103 +++++++++++++++++++++++++++++ src/components/app.rs | 8 +-- src/components/layout/layout.module.css | 19 ++++++ src/components/layout/mod.rs | 3 +- styles/fonts.scss | 16 +++++ styles/global.scss | 16 +++++ 10 files changed, 158 insertions(+), 22 deletions(-) delete mode 100644 global.scss create mode 100644 public/fonts/DraftingMono-ExtraLight.woff2 create mode 100644 public/fonts/Quicksand-Regular.ttf create mode 100644 readme.md create mode 100644 styles/fonts.scss create mode 100644 styles/global.scss diff --git a/Cargo.toml b/Cargo.toml index 1ffc006..68a9c52 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -62,4 +62,4 @@ lib-profile-release = "wasm-release" output_file="./.generated-style.scss" folders = ["./src/"] extensions = [".module.css"] -scss_prelude = "@import './global.scss';" +scss_prelude = "@import './styles/global.scss';" diff --git a/global.scss b/global.scss deleted file mode 100644 index f8ef821..0000000 --- a/global.scss +++ /dev/null @@ -1,13 +0,0 @@ -html { - margin: 0; - padding: 0; - background: linear-gradient(to bottom, #444, #222); - min-height: 100vh; -} - -body { - min-height: 100vh; - margin: 0 auto; - box-sizing: border-box; -} - diff --git a/public/fonts/DraftingMono-ExtraLight.woff2 b/public/fonts/DraftingMono-ExtraLight.woff2 new file mode 100644 index 0000000..eab6026 Binary files /dev/null and b/public/fonts/DraftingMono-ExtraLight.woff2 differ diff --git a/public/fonts/Quicksand-Regular.ttf b/public/fonts/Quicksand-Regular.ttf new file mode 100644 index 0000000..c03548a Binary files /dev/null and b/public/fonts/Quicksand-Regular.ttf differ diff --git a/readme.md b/readme.md new file mode 100644 index 0000000..fefdcb0 --- /dev/null +++ b/readme.md @@ -0,0 +1,103 @@ +# StormScribe + +Uhhh . . . a realtime collaborative wiki or something, because Confluence +is slow and everything else is a pain to set up + +I'll add more info here later + +--- + +### Acknowledgements + +Drafting Mono and Quicksand included in this project under the Open Font License + +Copyright 2021 The Drafting Mono Project Authors (https://github.com/indestructible-type/Drafting) + +Copyright 2011 The Quicksand Project Authors (https://github.com/andrew-paglinawan/QuicksandFamily), with Reserved Font Name “Quicksand”. + +
+ OFL Version 1.1 +
+This Font Software is licensed under the SIL Open Font License, Version 1.1 . This license is copied below, and is also available with a FAQ at: https://openfontlicense.org
+
+SIL OPEN FONT LICENSE
+=====================
+
+Version 1.1 - 26 February 2007
+
+PREAMBLE
+The goals of the Open Font License (OFL) are to stimulate worldwide
+development of collaborative font projects, to support the font creation
+efforts of academic and linguistic communities, and to provide a free and
+open framework in which fonts may be shared and improved in partnership
+with others.
+
+The OFL allows the licensed fonts to be used, studied, modified and
+redistributed freely as long as they are not sold by themselves. The
+fonts, including any derivative works, can be bundled, embedded,
+redistributed and/or sold with any software provided that any reserved
+names are not used by derivative works. The fonts and derivatives,
+however, cannot be released under any other type of license. The
+requirement for fonts to remain under this license does not apply
+to any document created using the fonts or their derivatives.
+
+DEFINITIONS
+"Font Software" refers to the set of files released by the Copyright
+Holder(s) under this license and clearly marked as such. This may
+include source files, build scripts and documentation.
+
+"Original Version" refers to the collection of Font Software components as
+distributed by the Copyright Holder(s).
+
+"Modified Version" refers to any derivative made by adding to, deleting,
+or substituting — in part or in whole — any of the components of the
+Original Version, by changing formats or by porting the Font Software to a
+new environment.
+
+"Author" refers to any designer, engineer, programmer, technical
+writer or other person who contributed to the Font Software.
+
+PERMISSION & CONDITIONS
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of the Font Software, to use, study, copy, merge, embed, modify,
+redistribute, and sell modified and unmodified copies of the Font
+Software, subject to the following conditions:
+
+1) Neither the Font Software nor any of its individual components,
+in Original or Modified Versions, may be sold by itself.
+
+2) Original or Modified Versions of the Font Software may be bundled,
+redistributed and/or sold with any software, provided that each copy
+contains the above copyright notice and this license. These can be
+included either as stand-alone text files, human-readable headers or
+in the appropriate machine-readable metadata fields within text or
+binary files as long as those fields can be easily viewed by the user.
+
+4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
+Software shall not be used to promote, endorse or advertise any
+Modified Version, except to acknowledge the contribution(s) of the
+Copyright Holder(s) and the Author(s) or with their explicit written
+permission.
+
+5) The Font Software, modified or unmodified, in part or in whole,
+must be distributed entirely under this license, and must not be
+distributed under any other license. The requirement for fonts to
+remain under this license does not apply to any document created
+using the Font Software.
+
+TERMINATION
+This license becomes null and void if any of the above conditions are
+not met.
+
+DISCLAIMER
+THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
+OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
+COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
+DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
+OTHER DEALINGS IN THE FONT SOFTWARE.
+
+
diff --git a/src/components/app.rs b/src/components/app.rs index 7e2676a..d93a870 100644 --- a/src/components/app.rs +++ b/src/components/app.rs @@ -51,12 +51,8 @@ pub fn App() -> impl IntoView { /// Renders the home page of your application. #[component] fn HomePage() -> impl IntoView { - // Creates a reactive value to update the button - let count = RwSignal::new(0); - let on_click = move |_| *count.write() += 1; - view! { -

"Welcome to Leptos!"

- +

Article

+

Article content here we guess?

} } diff --git a/src/components/layout/layout.module.css b/src/components/layout/layout.module.css index abcf876..7a6a818 100644 --- a/src/components/layout/layout.module.css +++ b/src/components/layout/layout.module.css @@ -33,6 +33,16 @@ padding: var(--container-padding) 0; } +.layout header a#siteTitle { + color: inherit; + text-decoration: none; + font-family: var(--font-family-heading); + + &:hover { + text-decoration: initial; + } +} + .layout nav { grid-row: 2 / 3; grid-column: 1 / 2; @@ -49,6 +59,15 @@ background-clip: padding-box; } +.layout main h1, +.layout main h2, +.layout main h3, +.layout main h4, +.layout main h5, +.layout main h6 { + font-family: var(--font-family-heading); +} + .layout footer { grid-column: 2 / 3; grid-row: 3 / 4; diff --git a/src/components/layout/mod.rs b/src/components/layout/mod.rs index 4b8061e..e688f5f 100644 --- a/src/components/layout/mod.rs +++ b/src/components/layout/mod.rs @@ -9,13 +9,12 @@ pub fn Layout() -> impl IntoView { view! {
-

Site Title

+ Site Title
-

Article