Giter VIP home page Giter VIP logo

fuwari's Introduction

🌱About me

  • Student majoring in Software Engineering
  • Golang, Java developer
  • Amateur UI designer and front-end developer
  • Contact: echo 'emVwaHlpcmRAZ21haWwuY29tCg==' | base64 -d
  • Lang: English, 中文, 少し日本語

fuwari's People

Contributors

evesunmaple avatar kkbt0 avatar l4ph avatar saicaca avatar see-night avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

fuwari's Issues

pnpm dev core dump

  1. os: 6.5.0-17-generic #17~22.04.1-Ubuntu
  2. run: pnpm dev
> [email protected] dev /home/xxx/project/fuwari
> astro dev


 astro  v4.4.15 ready in 16333 ms

┃ Local    http://localhost:4321/
┃ Network  use --host to expose
  1. then open chrome, core dump
16:35:14 watching for file changes...
16:35:27 [astro-icon] Loaded icons from fa6-brands, fa6-regular, fa6-solid, material-symbols
16:35:33 [200] / 3033ms
munmap_chunk(): invalid pointer
Aborted (core dumped)
 ELIFECYCLE  Command failed with exit code 134.

I do not konw the reason, please.

Illegal instruction (core dumped)

Hello,

I am trying to build locally and when I do, the error in the title shows up.

~/Projetos/fuwari [main ≡]> pnpm build  

> [email protected] build /home/alexandre/Projetos/fuwari
> astro build

11:52:10 [astro] Added src/env.d.ts types
11:52:11 [content] The "blog" collection does not have an associated folder in your `content` directory. Make sure the folder exists, or check your content config for typos.
11:52:11 [content] Types generated 0.94s
11:52:11 [build] output target: static
11:52:11 [build] Collecting build info...
11:52:11 [build] Completed in 1.28s.
11:52:11 [build] Building static entrypoints...
src/utils/content-utils.ts (1:8) "CollectionEntry" is not exported by "astro:content", imported by "src/utils/content-utils.ts".
11:52:32 [build] Completed in 20.69s.

 building client 
vite v4.5.0 building for production...
✓ 10 modules transformed.
dist/_astro/hoisted.5dad9063.css  14.45 kB │ gzip:  2.57 kB
dist/_astro/hoisted.99461e14.js   40.39 kB │ gzip: 18.28 kB
✓ built in 830ms
Completed in 0.85s.


 generating static routes 
▶ src/pages/index.astro
  └─ /index.html (+285ms)
▶ src/pages/archive/index.astro
  └─ /archive/index.html (+77ms)
▶ src/pages/archive/category/[category].astro
  └─ /archive/category/Example/index.html (+46ms)
▶ src/pages/archive/tag/[tag].astro
  ├─ /archive/tag/Markdown/index.html (+42ms)
  ├─ /archive/tag/Blogging/index.html (+46ms)
  ├─ /archive/tag/Demo/index.html (+47ms)
  ├─ /archive/tag/Fuwari/index.html (+33ms)
  ├─ /archive/tag/Customization/index.html (+19ms)
  ├─ /archive/tag/Example/index.html (+38ms)
  └─ /archive/tag/Video/index.html (+26ms)
▶ src/pages/about.astro
  └─ /about/index.html (+47ms)
▶ src/pages/posts/[slug].astro
  ├─ /posts/markdown/index.html (+30ms)
  ├─ /posts/cover/index.html (+38ms)
  └─ /posts/video/index.html (+22ms)
▶ src/pages/page/[page].astro
  └─ /page/1/index.html (+31ms)
▶ /
  └─ /index.html (+11ms)
Completed in 0.86s.


 generating optimized images 
Illegal instruction (core dumped)
 ELIFECYCLE  Command failed with exit code 132.

[BUG] Markdown render issue for code block

Test content:

---
title: Test
published: 2024-04-09
description: Test
tags: ["Test"]
category: How-to
draft: false
---
Content  
2. Try access secrets again
```bash
kubectl get secrets -n kube-system
To sign in, use a web browser to open the page https://microsoft.com/devicelogin and enter the code XXXXXXXXX to authenticate.
NAME                     TYPE                            DATA   AGE
bootstrap-token-sw3rck   bootstrap.kubernetes.io/token   4      35h
konnectivity-certs       Opaque                          3      35h
```
> **⚠ IMPORTANT**  
>  Due to the design of 

Old theme:
image

New theme: ("Line 6" appears)
image

I tested on VSC preview, the line 6 also not appearing:
image

Tested on other code blocks, and found the extra lines are not selectable:
image

I don't think I have my Markdown format wrong. So this line 6 should be rendered for error.

A consultation regarding the issue with relative paths.

Hello @saicaca !
I'm currently working on an issue with relative paths.
I found a library called astro-relative-links and when I tried using it, I was able to confirm that it works fine with relative paths.

I believe it's working correctly in my current branch, but if there are any issues or concerns, I would appreciate a review.

If there don't appear to be any issues, I plan to merge it into my current main branch and then create a pull request through the main branch.

my path fix branch

Issues installing dependencies with ONLY "^" value

I had issues with using "npm install" to install dependencies, it would return npm ERR! Invalid tag name "^" of package "@astrojs/check@^": I eventually fixed this by adding the most recent version after the "^" (e.g."^5.3.3") for both @astrojs/check and typescript. I was wondering if this was an issue only I had, or a re-occurring problem?

[Feature Request] Add Meta Description Tag to Web Pages

Upon checking the meta tags of the generated site, I found that the description is still set to its default configuration. This often functions as a headline when sharing the website externally, so it seems undesirable for it to remain in its default state.

<meta name="description" content="Astro description">

As for the actual modifications, we have a clear idea of what needs to be done and are currently working on making those changes. We plan to submit a pull request after completing these adjustments, so your review would be appreciated.

[Suggestion] Change the percentages for background color of clode block

Currently, the background color for code block:

--codeblock-bg: oklch(0.2 0.015 var(--hue)) oklch(0.17 0.015 var(--hue))

I find out the auto switch for light/dark theme does exists. But currently both of them are visually black and essentially no difference due to 0.015.
Is it ok to change the percentages a little bit?
For example: oklch(0.28 0.08 var(--hue))
image
image
image

Or make it lighter like oklch(0.35 0.1 var(--hue) / 0.95)
image
image
image

I know this is quiet subjective. I feel this is much better for light mode instead of "all black" without change.

backdrop-blur-lg not working

idk what messes up but the site does not show the blurred card background
whyplshelp
in the vercel preview in shows but on the actual site it does not work

.card-base {
    @apply backdrop-blur-lg rounded-[var(--radius-large)] overflow-hidden bg-[var(--card-bg)] transition;
}

ERROR ON SITE AND BASE URL CONFIGURATION

Hello there, Hope you're doing good.

I tried deploying this project in my github repo my-repo. But the href for all is not wokring as expected. When I click on "Archieve" or any other button which has routing, it is looking for username.github.io/archieve.
But what I expected is username.github.io/my-repo/archieve.

My configurations for astro.config.mjs file.

export default defineConfig({
site: "https://username.github.io/my-repo/",
base: "/my-repo/",

Can someone help me in this issue to get resolved.

Thanks in advance.

munmap_chunk() error when running `pnpm dev`

I am using WSL2 on Windows 11. I followed the steps in the README for this repo but was getting this error whenever I ran pnpm dev and clicked the localhost URL:

> $ pnpm astro dev                                              ⬡ 20.12.0 [±main ●]

> [email protected] astro /home/nads/personal-blog
> astro "dev"


 astro  v4.5.12 ready in 1026 ms

┃ Local    http://localhost:4321/
┃ Network  use --host to expose

17:10:58 watching for file changes...
17:11:02 [astro-icon] Loaded icons from fa6-brands, fa6-regular, fa6-solid, material-symbols
17:11:07 [200] / 3207ms
munmap_chunk(): invalid pointer
Aborted
 ELIFECYCLE  Command failed with exit code 134.

I found the fix for this issue here, which worked for me. You just have to add this to the package.json :

  "pnpm": {
		"overrides": {
			"vite-imagetools": "^6.2.7",
			"sharp": "^0.33.0"
		}
	}

Feel free to update the package.json with this if you want, or add a note in the README about this issue.
Thanks for your hard work!

[功能建议] 添加多级分类支持

类似于文件夹的功能,比如,

可以设置md文档的category属性为 Logs/Work/2024-4-3

那么在【分类】下,就会以文件夹的形式分层

  • Logs
    • Work
      • 2024-4-3.md
      • Java
        • Helloworld.md
      • C++
        • SomeMd.md
    • Sport
      • xxx.md

谢谢。

【功能建议】一个优雅的404页面

如果部署在GitHub pages,现在404会到GitHub 的404,报错不够优雅。

什么时候会用到404页面,我有个旧的博客,从hugo转移到该实现,导致url变了。如果没有一个优雅404让用户返回到home页面,用户会以为我博客跑路了。

下游我已经实现了,稍后(可能明后天)我会模仿该项目的风格实现界面提个pr。

我希望能反馈 utteranc.es 集成到 fuwari

utteranc.es是一个基于GitHub的评论实现。我按官方教程实现了与fuwari,而且工作的很好。我希望能把代码反馈到上流来。但是不知道fuwari本来计划的comment实现是怎么样的。这样的PR会不会被接受。和希望用什么的方式来实现,比如希望支持不同的comment provider的接入。

CleanShot 2024-04-08 at 20 46 30@2x

About、Archive、Tag默认的http code是301

curl -I https://correctroadh.github.io/archive/tag/%E6%80%9D%E8%80%83
HTTP/2 301
server: GitHub.com
content-type: text/html
permissions-policy: interest-cohort=()
location: https://correctroadh.github.io/archive/tag/思考/
access-control-allow-origin: *
strict-transport-security: max-age=31556952
expires: Sun, 14 Apr 2024 09:44:33 GMT
cache-control: max-age=600
x-proxy-cache: MISS
x-github-request-id: 8CE6:15F0FA:16B96BA:17A907C:661BA31A
accept-ranges: bytes
age: 0
date: Sun, 14 Apr 2024 09:34:33 GMT
via: 1.1 varnish
x-served-by: cache-nrt-rjtf7700024-NRT
x-cache: MISS
x-cache-hits: 0
x-timer: S1713087273.324086,VS0,VE230
vary: Accept-Encoding
x-fastly-request-id: 94b438e19fe2823a999bf9be47f9e3ccc051c05c
content-length: 162
curl -I https://correctroadh.github.io/about
HTTP/2 301
server: GitHub.com
content-type: text/html
permissions-policy: interest-cohort=()
location: https://correctroadh.github.io/about/
access-control-allow-origin: *
strict-transport-security: max-age=31556952
expires: Sun, 14 Apr 2024 09:45:35 GMT
cache-control: max-age=600
x-proxy-cache: MISS
x-github-request-id: 8BCA:8571A:128EF8:13D0DC:661BA367
accept-ranges: bytes
age: 0
date: Sun, 14 Apr 2024 09:35:35 GMT
via: 1.1 varnish
x-served-by: cache-nrt-rjtf7700071-NRT
x-cache: MISS
x-cache-hits: 0
x-timer: S1713087336.521143,VS0,VE162
vary: Accept-Encoding
x-fastly-request-id: 5a7d0a09c2ecc20a71746f1e2dd491c124bb67cf
content-length: 162

如果看到是301。我认为这个是不符合预期的。会导致SEO工具报错,影响SEO。

[Bug] The theme is loaded twice

Initially, I found this code in the src:
https://github.com/saicaca/fuwari/blob/main/src/layouts/Layout.astro#L211

function loadTheme() {
	if (localStorage.theme === 'dark' || (!('theme' in localStorage) &&
		window.matchMedia('(prefers-color-scheme: dark)').matches)) {
		document.documentElement.classList.add('dark');
		localStorage.theme = 'dark';
	} else {
		document.documentElement.classList.remove('dark');
		localStorage.theme = 'light';
	}
}

I understand this is a feature to confirm which theme the user want to use, so the blog can be presented with corresponding theme by localStorage.theme = 'light/dark';
Also, document.documentElement.classList.add('dark'); must be for changing the theme.

But there are some issues here:

  1. If users' network is not fast enough (or their computer has slow performance), and they use dark theme, it will splash a light theme and then switch the dark theme seconds later. It is also reproduceable on the current demo preview site. This can be a very bad experience.
    To reproduce: change throttling setting in F12 to "Slow 3G".
  2. IMO, I don't think store theme permanently for user is good experience. Because when user switch theme systemwide, the blog will not automatically change the theme accordingly by this design. For this, I made the PR with a new feature: #45

Markdown example post formatting

Is there a module I'm missing? Because the "markdown.md" example markdown post is not formatted correctly starting from the "Tables can look like this" section. The file mentions PanDoc, but I'm not sure Astro supports that?

For example, in the md file we are given:

size material color
---
9 leather brown
10 hemp canvas natural
11 glass transparent

but correct table formatting is:

| size | material | color|
|---|---|---|
|9 |leather |brown|
|10 |hemp canvas| natural|
|11 |glass |transparent|

该模板能否基于Notion实现?

  • 模板很棒!丝滑!流畅!
  • Github有一个基于NEXTJS框架开发的NotionNext-Notion建站工具
  • fuwari模板是否可以适用到Notion
  • 再次感谢作者,我简直太喜欢这个模板了!

  • Templates are awesome! Silky! Smooth!
  • Github has a NotionNext-Notion website building tool developed based on the NEXTJS framework
  • Whether the fuwari template can be applied to Notion
  • Thanks again to the author, I absolutely love this template!

[功能建议] 添加一个友链页面

CleanShot 2024-04-08 at 23 04 58@2x
我觉得可以在这里加一个Friends,来放友链。如果没有问题的话,我就提PR了,如果有问题的话,可以额外讨论一下,比如放在页脚。or 不做。

Error setting cover image

用标记符指定时也会出错。

 error   files[normalizedPath] is not a function
  File:
    C:\Users\**\**\**\src\components\misc\ImageBox.astro:22:38
  Code:
    21 |     let normalizedPath = "../../" + path.normalize(src).replace(/\\/g, "/");
    > 22 |     img = await (files[normalizedPath])();
         |                                      ^
      23 | }
      25 | ---

PostCard description should probably render markdown

Hi! I think that the PostCard component description should render the description as markdown. This is identical in the default case and comes with a few nice properties like linking and paragraphs in descriptions.

I did a mock-up on my own copy with the https://www.npmjs.com/package/@astropub/md library.

---
import { Markdown } from '@astropub/md'
---

<div class="transition text-75 mb-3.5 prose-base">
    <Markdown of={description} />
</div>

Something like this pretty much just works. Notably, I did add prose-base as a class because the default p margin is 0 and I thought it looked ugly. I'll not make a PR because this is trivial -- I'm very much not a web dev and will leave the styling to you :)

"ERROR: YOUR SITE COULD NOT BE BUILT:" while building Github Pages

I created a new repository from fuwari template and got an error during build.
Here are the changes I made from the template:
(lines 25 to 27 of astro.config.mjs)
Change before:
export default defineConfig({
site: "https://fuwari.vercel.app/",
base: "/",
After change:
export default defineConfig({
site: "https://<my_username>.github.io/",
base: "/<my_repo_name>",

The error is as follows.
image
image

Configuration file: none
To use retry middleware with Faraday v2.0+, install `faraday-retry` gem
YAML Exception reading /github/workspace/src/pages/archive/category/[category].astro: (<unknown>): mapping values are not allowed in this context at line [12](https://github.com/oizumi-photoclub/homepage/actions/runs/8627340187/job/23648437976#step:4:13) column 19 
             ERROR: YOUR SITE COULD NOT BE BUILT:
                    ------------------------------------
                    Invalid YAML front matter in /github/workspace/src/pages/archive/category/uncategorized.astro
Error:  Logging at level: debug GitHub Pages: github-pages v231 GitHub Pages: jekyll v3.9.5 Theme: jekyll-theme-primer Theme source: /usr/local/bundle/gems/jekyll-theme-primer-0.6.0 Requiring: jekyll-github-metadata Requiring: jekyll-seo-tag Requiring: jekyll-coffeescript Requiring: jekyll-commonmark-ghpages Requiring: jekyll-gist Requiring: jekyll-github-metadata Requiring: jekyll-paginate Requiring: jekyll-relative-links Requiring: jekyll-optional-front-matter Requiring: jekyll-readme-index Requiring: jekyll-default-layout Requiring: jekyll-titles-from-headings GitHub Metadata: Initializing... Source: /github/workspace/. Destination: /github/workspace/./_site Incremental build: disabled. Enable with --incremental Generating...

Errors on imports with `.ts` extension

There are quite a few errors, but I believe this is due to default export.
I will send a PR to fix these, but it may take some time as they are a bit numerous!
image
image

As it says "An import path can only end with a .ts extension when allowImportingTsExtensions is enabled", I think it is OK if you change ts.config, but I personally don't recommend it

update sidebar dynamically

Is there a way to update the tags on the sidebar after opening a post dynamically?

image

If possible, can you please guide me how to do that, i can create a PR if you prefer to add it as well? Thanks for the repo, looks amazing!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.