18 Commits

Author SHA1 Message Date
Sped0n
4b1f529589 refactor: migrate to vite for critical scss bundling, remove dart sass dependency
Signed-off-by: Sped0n <hi@sped0n.com>
2025-11-12 17:14:20 +08:00
Sped0n
8b3b5cd77a fix: use absolute URL for fw font in scss
Signed-off-by: Sped0n <hi@sped0n.com>
2025-11-12 17:14:20 +08:00
Sped0n
1d1f893c92 ci: format code 2025-11-12 00:10:06 +08:00
Sped0n
7d4bed3ba6 feat: use absolute URLs for assets
closes #473, closes #476

Signed-off-by: Sped0n <hi@sped0n.com>
2025-11-12 00:10:06 +08:00
Sped0n
72b830def9 refactor: remove multilingual support and language-specific fonts
Simplify to Geist font family for all languages. Update README, SCSS,
partials, and config. Fix style template execution order.

Signed-off-by: Sped0n <hi@sped0n.com>
2025-11-12 00:10:06 +08:00
Ryan
36721f8bf6 Bump deps (#515)
* chore: add nix flake for reproducible dev environment

Signed-off-by: Sped0n <hi@sped0n.com>

* refactor: migrate SCSS to modern Sass (@use/@forward)

Update mixins to use Sass module functions (map.has-key/get).
Configure Vite for modern Sass API.
Introduce _foundation.scss for forwarding core modules.

Signed-off-by: Sped0n <hi@sped0n.com>

* fix: replace deprecated _build with build in frontmatter

Signed-off-by: Sped0n <hi@sped0n.com>

* chore: add vcache.sh script for vercel build cache management

Signed-off-by: Sped0n <hi@sped0n.com>

* refactor: migrate to ESLint v9 flat config

Remove legacy .eslintrc.json, .eslintignore, and .prettierrc.json.

Add eslint.config.mjs with love, prettier, solid, and import rules.

Update devDependencies (eslint@9, @typescript-eslint@8, etc.) and scripts.

Minor TS fixes: remove eslint-disable, add error logging, simplify conditional.

Signed-off-by: Sped0n <hi@sped0n.com>

* chore: replace vcache.sh with vercel.sh for Vercel build process

Delete vcache.sh script.

Add vercel.sh: install Dart Sass v1.93.3, copy generated assets between
node_modules and project dirs, run vite:build + hugo build, then copy back.

Signed-off-by: Sped0n <hi@sped0n.com>

* chore: setup dart-sass and split build steps in GitHub workflow

Signed-off-by: Sped0n <hi@sped0n.com>

---------

Signed-off-by: Sped0n <hi@sped0n.com>
2025-11-11 20:20:29 +08:00
Ananth
9016cfb035 Add tamil translation (#430) 2025-01-03 16:19:41 +08:00
Spedon
febbd7d45d feat: migrate to Solid.js (#282)
* refactor: change hires loader function name

* feat: add loading transition animation and improve performance

* refactor: refactor gallery creation and update functions

* feat: update dependencies, configuration, and input file for solidjs

- Update dependencies in package.json
- Modify the input file in rollup.config.mjs
- Update tsconfig.json with new configuration options

* feat: update ESLint config for TypeScript and Solid integration

- Add `plugin:solid/typescript` to the ESLint config
- Add `prettier`, `@typescript-eslint`, and `solid` plugins to the ESLint config
- Remove the `overrides` and `plugins` properties from the ESLint config
- Modify the `memberSyntaxSortOrder` property in the ESLint config

* feat: update build scripts and configuration for Vite

* GitButler Integration Commit

This is an integration commit for the virtual branches that GitButler is tracking.

Due to GitButler managing multiple virtual branches, you cannot switch back and
forth between git branches and virtual branches easily. 

If you switch to another branch, GitButler will need to be reinitialized.
If you commit on this branch, GitButler will throw it away.

Here are the branches that are currently applied:
 - solid (refs/gitbutler/solid)
   branch head: dc6860991c
   - .eslintrc.json
   - assets/ts/main.tsx
   - assets/ts/desktop/stage.tsx
   - static/bundled/js/main.js
   - rollup.config.mjs
   - pnpm-lock.yaml
   - vite.config.ts
   - package.json
   - tsconfig.json
   - assets/ts/globalState.ts
   - assets/ts/mobile/collection.ts
   - assets/ts/container.ts
   - assets/ts/mobile/init.ts
   - assets/ts/mobile/gallery.ts
   - assets/ts/desktop/customCursor.ts
   - assets/ts/mobile/state.ts
   - assets/ts/globalUtils.ts
   - static/bundled/js/zXhbFx.js
   - static/bundled/js/EY5BO_.js
   - static/bundled/js/bBHMTk.js
   - assets/ts/nav.tsx
   - assets/ts/utils.ts
   - assets/ts/desktop/stageNav.ts
   - assets/ts/mobile/utils.ts
   - assets/ts/main.ts
   - assets/ts/desktop/state.ts
   - assets/ts/desktop/init.ts
   - assets/ts/state.tsx
   - assets/ts/desktop/utils.ts
   - assets/ts/nav.ts
   - assets/ts/resources.ts
   - assets/ts/desktop/stage.ts
   - static/bundled/js/GAHquF.js

Your previous branch was: refs/heads/solid

The sha for that commit was: dc6860991c

For more information about what we're doing here, check out our docs:
https://docs.gitbutler.com/features/virtual-branches/integration-branch

* refactor: remove .hide class from _base.scss file

* feat: migrate to Solid.js

* refactor: change i18n loading text with trailing dots

* fix: fix broken pnpm lock file

* chore: update eslint configuration for better code organization

- Update the eslint plugins array by removing newlines and maintaining plugins order
- Disable the rule "@typescript-eslint/non-nullable-type-assertion-style"
- Change the configuration of "sort-imports" rule

* feat: add tiny-invariant and eslint-plugin-solid to deps

* refactor: fix multiple eslint warnings

---------

Co-authored-by: GitButler <gitbutler@gitbutler.com>
2024-02-22 01:18:29 +08:00
Spedon
9fa1b718b8 feat: add loading indicator for desktop and mobile (#244)
* feat: add new CSS rule for hiding elements

- Add a new CSS rule for the class "hide" with a display property set to "none".

* feat: refactor image loading and navigation logic on desktop

- Add a line of code in `assets/ts/desktop/stage.ts` to reset the `src` of `elc` and add a class `hide` to it
- Add a line of code in `assets/ts/desktop/stage.ts` to call the `loader` function with `elc` as an argument
- Add a function `loader` in `assets/ts/desktop/stage.ts` to handle image loading and error events
- Modify the `initStageNav` function in `assets/ts/desktop/stageNav.ts` to watch the `isLoading` state and set custom cursor accordingly
- Modify the `initStageNav` function in `assets/ts/desktop/stageNav.ts` to handle close click events by calling the `handleClick` function and setting `isLoading` state to false
- Modify the `initStageNav` function in `assets/ts/desktop/stageNav.ts` to handle previous/next click events by calling the `handleClick` function only if `isLoading` is false
- Modify the `initStageNav` function in `assets/ts/desktop/stageNav.ts` to handle previous/next hover events by setting `loadedText` and updating custom cursor depending on `isLoading` state

* feat: refactor createGallery function and enhance loading functionality on mobile

- Add a loading text element to the gallery.scss file
- Add a loading indicator to the createGallery function in gallery.ts
- Modify the createGallery function in gallery.ts to hide the loading text element on image load
- Move the image element append logic to the parent container in the createGallery function in gallery.ts

* feat: update translations and add new loading translation in i18n files

* chore: remove css source map

* chore: modify build command to ignore css source map

* refactor: remove unnecessary style

* fix: fix desktop cursor text transition bug
2024-01-20 23:34:13 +08:00
Spedon
30a01cfd63 minor update (#195)
* refactor: update package.json dependencies and build tools

* feat: bump up geist font version

* refactor: non-nullable-type-assertion-style bypass

* chore: bump up version in package.json

* docs: update get started doc

* styles: prettier format
2023-12-14 13:48:45 +08:00
Spedon
9c073e98e1 v0.0.2 (#144)
* chore(Geist): bump geist font to v1.0.1

* refactor(_typography.scss): split the CSS lang tag to ensure compatibility with Chromium-based browsers

* refactor(stage.ts): bump up preload count on desktop

* feat(params.toml): add support for user defined resize option

* feat(_fonts.scss): add a new font file to better support fullwidth plus and minus

* refactor(info): update info

* chore(build.yml): update branch name for updating bundled artifacts to include the current date

* chore(package.json): update version from 0.0.1 to v0.0.2 to reflect changes made in the codebase
2023-11-10 21:00:09 +08:00
Sped0n
f4eda42785 feat(i18n): add translations for the new languages (de, es, fr, it, CJK) 2023-11-03 14:19:06 +08:00
Sped0n
2229c56b1e chore(fonts): update font files and font-family declarations
- Update font files for different languages: NotoSansCJKsc-Regular.woff2, NotoSansCJKtc-Regular.woff2, NotoSansCJKjp-Regular.woff2, NotoSansCJKkr-Regular.woff2, NotoSans-Regular.woff2
- Update font-family declarations in _typography.scss to use the new font files:
  - Change font-family for body to 'sans-serif'
  - Change font-family for button to 'Noto Sans', sans-serif
- Add font-family declarations for different languages in _typography.scss:
  - For English language (en), use 'Geist', sans-serif
  - For Simplified Chinese language (zh-cn, zh-sg), use 'Noto Sans', 'Noto Sans CJK SC', sans-serif
  - For Traditional Chinese language (zh-hk, zh-mo, zh-tw), use 'Noto Sans', 'Noto Sans CJK TC', sans-serif
  - For Japanese language (ja), use 'Noto Sans', 'Noto Sans CJK JP', sans-serif
  - For Korean language (ko), use 'Noto Sans', 'Noto Sans CJK KR', sans-serif
2023-11-03 08:47:11 +08:00
Sped0n
7b48cf6e91 chore(font.scss): update font-face declaration for 'Geist' font and add font-display property for better font loading performance
chore(font.scss): add font-face declaration for 'fw' font and set font-display property for better font loading performance
chore(typography.scss): update font-family property for body element to use 'Geist' font as the primary font
chore(typography.scss): update font-family property for button element to use 'fw' font as the primary font
2023-11-01 23:02:37 +08:00
Sped0n
3d88d5a243 style(base.scss): remove empty line at the end of the file for consistency
style(nav.scss): remove unused import statement for mixins in _core folder
2023-11-01 23:02:02 +08:00
Sped0n
144132ae72 fix(fonts): update font file path in _font.scss to use the new woff2 file format
fix(fonts): remove HelveticaNowText-Regular.woff font file and add HelveticaNowText-Regular.woff2 font file
2023-10-30 15:51:17 +08:00
Sped0n
2e3fc3d7b6 feat(reset.scss): add new CSS reset file to reset default styles and improve cross-browser consistency
The new CSS reset file is added to the project. This file is used to reset default styles applied by the user agent stylesheet and provide a clean starting point for styling. The reset file includes various CSS rules to remove default styles and improve cross-browser consistency.

Some of the changes made in the reset.scss file include:
- Removing all styles of the "User-Agent-Stylesheet" except for the 'display' property to solve Firefox SVG sprite bug and prevent a bug in Chrome that breaks the CSS hyphens property.
- Setting the box-sizing property to border-box for all elements and pseudo-elements to ensure consistent box sizing.
- Fixing the increase in font-size on mobile Safari in landscape mode.
- Reapplying the pointer cursor for anchor tags and buttons.
- Removing list styles (bullets/numbers) from ordered lists, unordered lists, menus, and summary elements.
- Setting max-inline-size and max-block-size properties to 100% for images to prevent them from exceeding their container.
- Removing spacing between cells in tables.
- Fixing an issue in Safari where the user-select:none property doesn't work on the <body> text input.
- Reverting the 'white-space' property for textarea elements on Safari.
- Applying minimum styles to allow styling of the meter element.
- Reverting all styles for preformatted text.
- Resetting the default text opacity of input placeholders.
- Fixing the 'hidden' attribute to use display: none instead of the attribute itself.
- Fixing a bug in Chromium browsers where the content editable attribute doesn't work properly.
- Applying the draggable feature for elements with the draggable attribute set to 'true'.
- Reverting the native behavior of modal dialogs.

These changes are made to ensure a consistent and predictable starting point for styling in the project and improve cross-browser compatibility.
2023-10-29 22:10:02 +08:00
Sped0n
ca4f2d2902 feat(scss): add core base styles
Add a new file `_base.scss` to the `_core` directory. This file contains base styles for the entire application. The styles include setting font smoothing properties, setting the background color of the body, and disabling overscroll behavior on the html and body elements. Additionally, the styles set the cursor property to pointer for anchor tags and buttons.

feat(scss): add core font styles

Add a new file `_font.scss` to the `_core` directory. This file defines the `HelveticaNow` font face and specifies the font weight and style.

feat(scss): add core mixins

Add a new file `_mixins.scss` to the `_core` directory. This file defines mixins for working with breakpoints. The mixins allow for specifying styles based on minimum and maximum widths of breakpoints defined in the `$breakpoints` map.

feat(scss): add core typography styles

Add a new file `_typography.scss` to the `_core` directory. This file defines typography styles for the body element. The styles set the line height, font size, and font family. Additionally, the styles use the `min-width` mixin to increase the font size at tablet and laptop breakpoints.

feat(scss): add partial customCursor styles

Add a new file `_customCursor.scss` to the `_partial` directory. This file defines styles for a custom cursor. The styles position the cursor element, set its color and blend mode, and define an inner element for the cursor.

feat(scss): add partial stage styles

Add a new file `_stage.scss` to the `_partial` directory. This file defines styles for a stage element. The styles position the stage element, set its width and height, and define styles for an image element within the stage.

feat(scss): add partial stageNav styles

Add a new file `_stageNav.scss` to the `_partial` directory. This file defines styles for a stage navigation overlay. The styles position the overlay element and set its width and height. The styles also define an inactive state for the overlay.

feat(scss): add variables

Add a new file `_variables.scss` to the root directory. This file defines CSS variables for various aspects of the application, such as window height, navigation height, spacing, and z-index values.

feat(scss): import styles in main style.scss

Add import statements for the newly created files in the `style.scss` file. This ensures that the
2023-10-29 22:09:36 +08:00