Giter Site home page Giter Site logo

qqke / freya Goto Github PK

View Code? Open in Web Editor NEW

This project forked from marc2332/freya

0.0 0.0 0.0 5.8 MB

Native GUI library for πŸ¦€ Rust powered by 🧬 Dioxus and 🎨 Skia.

Home Page: https://freyaui.dev/

License: MIT License

Shell 0.01% JavaScript 0.16% Rust 95.71% CSS 1.95% Handlebars 1.29% Astro 0.88%

freya's Introduction

Freya πŸ¦€

Freya logo

Discord Server Github Sponsors codecov

Website | Nightly Docs | Stable Docs | Book | Discord

Freya is a native GUI library for Rust powered by 🧬 Dioxus and 🎨 Skia.

⚠️ It's currently work in progress and not usable for production, but you can already play with it! You can join the Discord server if you have any question or issue.



fn app() -> Element {
    let mut count = use_signal(|| 0);

    render!(
        rect {
            height: "50%",
            width: "100%",
            main_align: "center",
            cross_align: "center",
            background: "rgb(0, 119, 182)",
            color: "white",
            shadow: "0 4 20 5 rgb(0, 0, 0, 80)",
            label {
                font_size: "75",
                font_weight: "bold",
                "{count}"
            }
        }
        rect {
            height: "50%",
            width: "100%",
            main_align: "center",
            cross_align: "center",
            direction: "horizontal",
            Button {
                onclick: move |_| count += 1,
                label { "Increase" }
            }
            Button {
                onclick: move |_| count -= 1,
                label { "Decrease" }
            }
        }
    )
}

Freya Demo

Sponsors πŸ€—

Thanks to my sponsors for supporting this project! πŸ˜„

Alberto Mendezandar1an

Want to try it? πŸ€”

⚠️ First, see Environment setup.

Clone this repo and run:

cargo run --example counter

You can also try freya-template

Usage πŸ“œ

Add Freya and Dioxus as dependencies:

freya = "0.2"
dioxus = { version = "0.5", features = ["macro", "hooks"], default-features = false }

Features ✨

  • ⛏️ Built-in components (button, scroll views, switch and more)
  • πŸš‡ Built-in hooks library (animations, text editing and more)
  • πŸ” Built-in devtools panel (experimental ⚠️)
  • 🧰 Built-in headless testing runner for components
  • 🎨 Theming support (not extensible yet ⚠️)
  • πŸ›©οΈ Cross-platform (Windows, Linux, MacOS)
  • πŸ–ΌοΈ SKSL Shaders support
  • πŸ”„οΈ Dioxus Hot-reload support
  • πŸ“’ Multi-line text editing (experimental ⚠️)
  • 🦾 Basic Accessibility Support (experimental ⚠️)
  • 🧩Compatible with dioxus-sdk and other Dioxus renderer-agnostic libraries

Goals 😁

  • Performant and low memory usage
  • Good developer experience
  • Cross-platform support
  • Decent Accessibility support
  • Useful testing APIs
  • Useful and extensible components and hooks

MIT License

freya's People

Contributors

marc2332 avatar tigerros avatar renovate[bot] avatar tropix126 avatar trickypr avatar dependabot[bot] avatar piny4man avatar aspnxdd avatar eventualbuddha avatar ealmloff avatar katyo avatar wusyong avatar olshamb avatar tahatesser avatar taym95 avatar kobutri avatar shuai132 avatar

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.