-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #44 from X-FRI/dev
[website]: init
- Loading branch information
Showing
13 changed files
with
789 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: npm | ||
directory: "/" | ||
schedule: | ||
interval: daily | ||
open-pull-requests-limit: 20 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
name: stoream-website | ||
|
||
on: | ||
push: | ||
branches: | ||
- dev | ||
|
||
jobs: | ||
pages: | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
working-directory: ./stoream-website | ||
|
||
strategy: | ||
matrix: | ||
dotnet-version: [ '9.0' ] | ||
node-version: [20] | ||
|
||
permissions: | ||
contents: write | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
submodules: recursive | ||
|
||
- uses: actions/checkout@v3 | ||
- name: Setup .NET Core SDK ${{ matrix.dotnet-version }} | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: ${{ matrix.dotnet-version }} | ||
|
||
- uses: actions/checkout@v4 | ||
- name: Install pnpm | ||
uses: pnpm/action-setup@v3 | ||
with: | ||
version: 9 | ||
|
||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
cache: 'pnpm' | ||
cache-dependency-path: ./stoream-website/pnpm-lock.yaml | ||
|
||
- name: Install dependencies | ||
run: dotnet restore && dotnet tool restore && pnpm install | ||
|
||
- name: Build | ||
run: dotnet fable && pnpm exec vite build | ||
|
||
- name: Deploy | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: ./dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"version": 1, | ||
"isRoot": true, | ||
"tools": { | ||
"fable": { | ||
"version": "4.18.0", | ||
"commands": [ | ||
"fable" | ||
], | ||
"rollForward": false | ||
}, | ||
"fantomas": { | ||
"version": "6.3.7", | ||
"commands": [ | ||
"fantomas" | ||
], | ||
"rollForward": false | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
[*.fs] | ||
indent_size = 2 | ||
max_line_length = 80 | ||
fsharp_space_before_parameter = true | ||
fsharp_space_before_class_constructor = true | ||
fsharp_space_before_uppercase_invocation = true | ||
fsharp_space_before_lowercase_invocation = false | ||
fsharp_space_before_member = true | ||
fsharp_space_before_colon = false | ||
fsharp_space_after_comma = true | ||
fsharp_space_around_delimiter = true | ||
fsharp_space_before_semicolon = false | ||
fsharp_space_after_semicolon = true | ||
fsharp_newline_between_type_definition_and_members = true | ||
fsharp_align_function_signature_to_indentation = true | ||
fsharp_max_if_then_short_width = 80 | ||
fsharp_max_if_then_else_short_width = 80 | ||
fsharp_max_infix_operator_expression = 80 | ||
fsharp_max_record_width = 80 | ||
fsharp_max_record_number_of_items = 2 | ||
fsharp_record_multiline_formatter = number_of_items | ||
fsharp_max_array_or_list_width = 80 | ||
fsharp_max_array_or_list_number_of_items = 2 | ||
fsharp_array_or_list_multiline_formatter = number_of_items | ||
fsharp_max_value_binding_width = 80 | ||
fsharp_max_function_binding_width = 80 | ||
fsharp_max_dot_get_expression_width = 80 | ||
fsharp_newline_before_multiline_computation_expression = true | ||
fsharp_alternative_long_member_definitions = true | ||
fsharp_blank_lines_around_nested_multiline_expressions = true | ||
fsharp_keep_max_number_of_blank_lines = 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
bin/ | ||
obj/ | ||
.vscode/ | ||
.idea/ | ||
fable_modules/ | ||
node_modules/ | ||
dist/ | ||
|
||
*.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
module Stoream.WebSite.Main | ||
|
||
open Browser.Dom | ||
open Feliz | ||
|
||
[<ReactComponent>] | ||
let Title () = | ||
Html.section | ||
[ prop.className "container is-primary" | ||
prop.children | ||
[ Html.div | ||
[ prop.className "hero-body" | ||
prop.children | ||
[ Html.div | ||
[ prop.className "content" | ||
prop.children | ||
[ Html.h1 | ||
[ prop.className "title block" | ||
prop.text "Stoream" ] | ||
|
||
Html.p "Minimalist self-hosted network disk system" ] ] ] ] ] ] | ||
|
||
[<ReactComponent>] | ||
let App () = | ||
Html.div | ||
[ prop.className "fixed-grid has-1-cols mt-6 ml-6" | ||
prop.children | ||
[ Html.div [ prop.className "grid"; prop.children [ Title () ] ] ] ] | ||
|
||
ReactDOM.createRoot(document.getElementById "root").render(App ()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import { createElement } from "react"; | ||
import React from "react"; | ||
import { createObj } from "./fable_modules/fable-library-js.4.18.0/Util.js"; | ||
import { Interop_reactApi } from "./fable_modules/Feliz.2.7.0/./Interop.fs.js"; | ||
import { ofArray } from "./fable_modules/fable-library-js.4.18.0/List.js"; | ||
import { createRoot } from "react-dom/client"; | ||
|
||
export function Title() { | ||
let elems_2, elems_1, elems; | ||
return createElement("section", createObj(ofArray([["className", "container is-primary"], (elems_2 = [createElement("div", createObj(ofArray([["className", "hero-body"], (elems_1 = [createElement("div", createObj(ofArray([["className", "content"], (elems = [createElement("h1", { | ||
className: "title block", | ||
children: "Stoream", | ||
}), createElement("p", { | ||
children: ["Minimalist self-hosted network disk system"], | ||
})], ["children", Interop_reactApi.Children.toArray(Array.from(elems))])])))], ["children", Interop_reactApi.Children.toArray(Array.from(elems_1))])])))], ["children", Interop_reactApi.Children.toArray(Array.from(elems_2))])]))); | ||
} | ||
|
||
export function App() { | ||
let elems_1, elems; | ||
return createElement("div", createObj(ofArray([["className", "fixed-grid has-1-cols mt-6 ml-6"], (elems_1 = [createElement("div", createObj(ofArray([["className", "grid"], (elems = [createElement(Title, null)], ["children", Interop_reactApi.Children.toArray(Array.from(elems))])])))], ["children", Interop_reactApi.Children.toArray(Array.from(elems_1))])]))); | ||
} | ||
|
||
createRoot(document.getElementById("root")).render(createElement(App, null)); | ||
|
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
|
||
<head> | ||
<meta charset="UTF-8" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>Fable</title> | ||
<link rel="stylesheet" href="/bulma.min.css"> | ||
</head> | ||
|
||
<body> | ||
<div id="root"></div> | ||
<script type="module" src="/Program.fs.js"></script> | ||
</body> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"name": "stoream-website", | ||
"version": "1.0.0", | ||
"main": "Program.fs.js", | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
}, | ||
"keywords": [], | ||
"author": "", | ||
"license": "ISC", | ||
"description": "", | ||
"devDependencies": { | ||
"vite": "^5.2.12" | ||
}, | ||
"dependencies": { | ||
"react": "^18.3.1", | ||
"react-dom": "^18.3.1" | ||
} | ||
} |
Oops, something went wrong.