Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat(add, Fix): change font size, new flake #32

Merged
merged 2 commits into from
Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
96 changes: 96 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

49 changes: 49 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
{
description = "A Blog";

inputs = {
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
rust-overlay.url = "github:oxalica/rust-overlay";
};

outputs = {
self,
nixpkgs,
rust-overlay,
...
}: let
system = "x86_64-linux";
overlays = [(import rust-overlay)];
#pkgs = nixpkgs.legacyPackages.${system};
pkgs = import nixpkgs {
inherit system overlays;
};
rust = pkgs.buildPackages.rust-bin.stable.latest.minimal;
nativeBuildInputs = with pkgs; [
rust
leptosfmt
cargo-watch
miniserve
openssl
];
buildInputs = with pkgs; [
pkg-config
];
in {
formatter.x86_64-linux = nixpkgs.legacyPackages.${system}.alejandra;
environment.variables = {
PKG_CONFIG_PATH = "${pkgs.openssl.dev}/lib/pkgconfig";
};
devShells.${system}.default = pkgs.mkShell {
inherit nativeBuildInputs buildInputs;
shellHook = ''mkdir -p out
echo "Bienvenido al Blog."
echo -e 'puede usar los comandos:
\x1b[93m#[Para compilar y ejecutar el servidor web local]\x1b[0m
cargo watch -x run --shell "npx tailwindcss -i ./input.css -o ./out/output.css && cargo run" &
\x1b[93m#[Para ejecutar o correr los archivos estáticos de tu sitio web localmente]\x1b[0m
miniserve -- out --index index.html'
'';
};
};
}
13 changes: 10 additions & 3 deletions src/components/feature_articles.rs
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ pub fn EstaSemanaEnRustCard(article: Article) -> impl IntoView {
<div class="absolute backdrop-blur flex flex-row bg-black/50 text-white w-full h-full items-center z-10 top-0 left-0 p-5">
<div class="w-full h-full flex flex-col gap-5 lg:pr-10 md:pt-10">
<div class="w-full items-center justify-between">
<h2 class="text-2xl lg:text-[3.5rem] font-semibold font-work-sans tracking-widest max-w-[24ch] text-balance">
<h2
class="text-2xl lg:text-[3.5rem] font-semibold font-work-sans tracking-widest max-w-[24ch] text-balance"
style="line-height: 0.8;"
Comment on lines +104 to +105
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No me deja hacer suggestion porque esta mergeado pero no se deberian de usar estilos inline, se penalizan.
En su lugar usar la clase detailwind leading

>
"Esta semana en Rust"
<span class="md:hidden text-2xl lg:text-[3.5rem] font-semibold font-work-sans tracking-widest max-w-[24ch] text-balance">
# {article.number_of_week.unwrap()}
Expand All @@ -124,8 +127,12 @@ pub fn EstaSemanaEnRustCard(article: Article) -> impl IntoView {
</div>
</div>
<div class="hidden md:flex">
<div class="bg-black rounded-full w-40 h-40 md:text-8xl flex items-center justify-center mb-10">
# {article.number_of_week.unwrap()}
<div
class="bg-black rounded-full w-40 h-40 md:text-8xl flex items-center justify-center mb-10"
style="font-size: 3.5rem;"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

En lugar de estilos inline usar la clase text

>
#
{article.number_of_week.unwrap()}
</div>
</div>
</div>
Expand Down
Loading