From 81de4ef14866f89c4e4e36d144a61323a1298ccd Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Wed, 21 Aug 2024 12:47:46 +0200 Subject: [PATCH] introduce editorconfig --- .editorconfig | 18 ++++++ .github/workflows/deploy.yml | 2 +- deploy.sh | 2 +- docs-archive/stardust-protocol/protocol.md | 14 ++--- .../server/objects/drawable.md | 2 +- .../stardust-protocol/server/objects/field.md | 2 +- .../stardust-protocol/server/objects/input.md | 2 +- .../server/objects/spatial.md | 2 +- .../stardust-protocol/server/types/Model.md | 2 +- .../stardust-protocol/server/types/Node.md | 2 +- .../stardust-protocol/server/types/Spatial.md | 2 +- .../stardust-protocol/server/types/Zone.md | 2 +- .../server/types/field/BoxField.md | 2 +- .../server/types/field/CylinderField.md | 2 +- .../server/types/field/Field.md | 2 +- .../server/types/field/SphereField.md | 2 +- .../server/types/input/InputHandler.md | 2 +- .../server/types/input/InputMethod.md | 2 +- .../types/input/inputtypes/HandInput.md | 56 ++++++++++--------- docusaurus.config.js | 2 +- sidebars.js | 13 +++-- src/css/custom.css | 2 +- src/pages/roadmap.md | 2 +- static/CNAME | 2 +- 24 files changed, 83 insertions(+), 58 deletions(-) create mode 100644 .editorconfig diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 00000000..56b890b5 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,18 @@ +root = true + +[*] +indent_style = space +indent_size = 2 +tab_width = 2 +end_of_line = lf +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true + + +[*.md] +trim_trailing_whitespace = false +indent_size = 1 + +[*.{css,js,json}] +indent_style = tab diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 12d18835..a8f34d9b 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -32,4 +32,4 @@ jobs: # The GH actions bot is used by default if you didn't specify the two fields. # You can swap them out with your own user credentials. user_name: github-actions[bot] - user_email: 41898282+github-actions[bot]@users.noreply.github.com \ No newline at end of file + user_email: 41898282+github-actions[bot]@users.noreply.github.com diff --git a/deploy.sh b/deploy.sh index c42e9bfb..b79bd756 100644 --- a/deploy.sh +++ b/deploy.sh @@ -1,3 +1,3 @@ #!/bin/sh -GIT_USER=$1 USE_SSH=true yarn deploy \ No newline at end of file +GIT_USER=$1 USE_SSH=true yarn deploy diff --git a/docs-archive/stardust-protocol/protocol.md b/docs-archive/stardust-protocol/protocol.md index 7a12db78..1557dcdd 100644 --- a/docs-archive/stardust-protocol/protocol.md +++ b/docs-archive/stardust-protocol/protocol.md @@ -11,12 +11,12 @@ Every message uses [flatbuffers](https://google.github.io/flatbuffers/) and [fle namespace StardustXR; table Message { - type: ubyte; - id: uint; - object: string; - method: string; - error: string; - data:[ubyte] (flexbuffer); + type: ubyte; + id: uint; + object: string; + method: string; + error: string; + data:[ubyte] (flexbuffer); } root_type Message; @@ -75,4 +75,4 @@ A `Vector` of 2 `double` is treated as a `Vector2`. ### Vector3 A `Vector` of 3 `double` is treated as a `Vector3`. ### Quaternion -A `Vector` of 4 `double` is treated as a `Quaternion`. \ No newline at end of file +A `Vector` of 4 `double` is treated as a `Quaternion`. diff --git a/docs-archive/stardust-protocol/server/objects/drawable.md b/docs-archive/stardust-protocol/server/objects/drawable.md index a793988a..2ad6ac4e 100644 --- a/docs-archive/stardust-protocol/server/objects/drawable.md +++ b/docs-archive/stardust-protocol/server/objects/drawable.md @@ -10,4 +10,4 @@ Creates a new [Model](../types/Model.md) at `/model/[name]` with parent at `spac Sets the sky texture to be the image (HDR) at the absolute `path`. ### `setSkylight(string path)` -Sets the ambient lighting (using spherical harmonics) to the HDR at the absolute `path`. \ No newline at end of file +Sets the ambient lighting (using spherical harmonics) to the HDR at the absolute `path`. diff --git a/docs-archive/stardust-protocol/server/objects/field.md b/docs-archive/stardust-protocol/server/objects/field.md index 19e8fade..dcfaadce 100644 --- a/docs-archive/stardust-protocol/server/objects/field.md +++ b/docs-archive/stardust-protocol/server/objects/field.md @@ -10,4 +10,4 @@ Creates a new [BoxField](../types/field/BoxField.md) at `/field/[name]` with par Creates a new [CylinderField](../types/field/CylinderField.md) at `/field/[name]` with parent at `spacePath`. ### `createSphereField(string name, string spacePath, Vector3 origin, float radius)` -Creates a new [SphereField](../types/field/SphereField.md) at `/field/[name]` with parent at `spacePath`. \ No newline at end of file +Creates a new [SphereField](../types/field/SphereField.md) at `/field/[name]` with parent at `spacePath`. diff --git a/docs-archive/stardust-protocol/server/objects/input.md b/docs-archive/stardust-protocol/server/objects/input.md index e4aa5a61..efa62876 100755 --- a/docs-archive/stardust-protocol/server/objects/input.md +++ b/docs-archive/stardust-protocol/server/objects/input.md @@ -13,4 +13,4 @@ Creates a new [InputHandler](../types/input/InputHandler.md) with the specified ## Methods ### `Vector> getInputHandlers(string spacePath, bool excludeSelf)` -Returns a list of all [InputHandler](../types/input/InputHandler.md) UUIDs and their positions (relative to the space at `spacePath`), as well as puts aliases to those handlers in `/input/global_handler/[UUID]`. Excludes handlers from this client if `excludeSelf` is true. \ No newline at end of file +Returns a list of all [InputHandler](../types/input/InputHandler.md) UUIDs and their positions (relative to the space at `spacePath`), as well as puts aliases to those handlers in `/input/global_handler/[UUID]`. Excludes handlers from this client if `excludeSelf` is true. diff --git a/docs-archive/stardust-protocol/server/objects/spatial.md b/docs-archive/stardust-protocol/server/objects/spatial.md index 3aed219c..b904d17a 100644 --- a/docs-archive/stardust-protocol/server/objects/spatial.md +++ b/docs-archive/stardust-protocol/server/objects/spatial.md @@ -7,4 +7,4 @@ Object managing spatial objects and spatial manipulation. Creates a new [Spatial](../types/Spatial.md) at `/spatial/spatial/[name]` with parent at `spacePath`. ### `createZone(string name, string fieldPath, string spacePath, Vector3 origin, Quat orientation, string callbackPath, string callbackMethod)` -Creates a new [Zone](../types/Zone.md) at `/spatial/zone/[name]` with parent at `spacePath` and field at `fieldPath`. The arguments `callbackPath` and `callbackMethod` refer to a callback method accepting a `Vector` of 2 `TypedVector`s, the first being a list of names of nodes that have just entered the field and the second being names of nodes that left (as `string`). \ No newline at end of file +Creates a new [Zone](../types/Zone.md) at `/spatial/zone/[name]` with parent at `spacePath` and field at `fieldPath`. The arguments `callbackPath` and `callbackMethod` refer to a callback method accepting a `Vector` of 2 `TypedVector`s, the first being a list of names of nodes that have just entered the field and the second being names of nodes that left (as `string`). diff --git a/docs-archive/stardust-protocol/server/types/Model.md b/docs-archive/stardust-protocol/server/types/Model.md index f8896dc4..8a8c348b 100644 --- a/docs-archive/stardust-protocol/server/types/Model.md +++ b/docs-archive/stardust-protocol/server/types/Model.md @@ -38,4 +38,4 @@ Sets the material property `propertyName` on this model's submesh at `submeshInd |`emission` | `string` | Path to the emission texture of the material (if it has one). | |`metal` | `string` | Path to the metalness texture of the material (if it has one). | |`normal` | `string` | Path to the normal map texture of the material (if it has one). | -|`occlusion` | `string` | Path to the occlusion map texture of the material (if it has one). | \ No newline at end of file +|`occlusion` | `string` | Path to the occlusion map texture of the material (if it has one). | diff --git a/docs-archive/stardust-protocol/server/types/Node.md b/docs-archive/stardust-protocol/server/types/Node.md index 2399ba00..fa63e215 100644 --- a/docs-archive/stardust-protocol/server/types/Node.md +++ b/docs-archive/stardust-protocol/server/types/Node.md @@ -10,4 +10,4 @@ A base type for all other types that exist in 3D space. Destroy this node immediately, as well as all its children if it has any. ### `setEnabled(bool enabled)` -Set if this node is enabled or not, for example a disabled model will not render and a disabled input handler will not recieve input. \ No newline at end of file +Set if this node is enabled or not, for example a disabled model will not render and a disabled input handler will not recieve input. diff --git a/docs-archive/stardust-protocol/server/types/Spatial.md b/docs-archive/stardust-protocol/server/types/Spatial.md index 208c51f4..a558918b 100644 --- a/docs-archive/stardust-protocol/server/types/Spatial.md +++ b/docs-archive/stardust-protocol/server/types/Spatial.md @@ -53,4 +53,4 @@ Enable/disable this spatial's zoneable property. ## Methods ### `Vector getTransform(null)` -Returns the `origin`, `orientation`, and `scale` of this spatial relative to its parent. \ No newline at end of file +Returns the `origin`, `orientation`, and `scale` of this spatial relative to its parent. diff --git a/docs-archive/stardust-protocol/server/types/Zone.md b/docs-archive/stardust-protocol/server/types/Zone.md index 620bf0cc..30de2c8f 100644 --- a/docs-archive/stardust-protocol/server/types/Zone.md +++ b/docs-archive/stardust-protocol/server/types/Zone.md @@ -15,4 +15,4 @@ Returns `true`/`false` if the [Spatial](Spatial) is captured by this zone or ano Captures the [Spatial](Spatial) at `spatialUUID` if that [Spatial](Spatial) exists and is accessible by this zone. This means that the [Spatial](Spatial) cannot be seen or affected by other zones unless a zone is closer to the [Spatial](Spatial) than this zone. ### `release(string spatialUUID)` -Uncaptures the [Spatial](Spatial) at `spatialUUID` so any zone the [Spatial](Spatial) is inside can access it. \ No newline at end of file +Uncaptures the [Spatial](Spatial) at `spatialUUID` so any zone the [Spatial](Spatial) is inside can access it. diff --git a/docs-archive/stardust-protocol/server/types/field/BoxField.md b/docs-archive/stardust-protocol/server/types/field/BoxField.md index 1fef049d..d2d3a9a0 100644 --- a/docs-archive/stardust-protocol/server/types/field/BoxField.md +++ b/docs-archive/stardust-protocol/server/types/field/BoxField.md @@ -4,4 +4,4 @@ This field is in a rectangular prism shape. ## Properties ### `setSize(Vector3 size)` -Sets the size of the box. \ No newline at end of file +Sets the size of the box. diff --git a/docs-archive/stardust-protocol/server/types/field/CylinderField.md b/docs-archive/stardust-protocol/server/types/field/CylinderField.md index 2415d568..1c9b11f2 100644 --- a/docs-archive/stardust-protocol/server/types/field/CylinderField.md +++ b/docs-archive/stardust-protocol/server/types/field/CylinderField.md @@ -4,4 +4,4 @@ A cylinder shaped field defined by radius and length, along the forward vector. ## Properties ### `setSize(Vector3 size)` -Sets the size of the box. \ No newline at end of file +Sets the size of the box. diff --git a/docs-archive/stardust-protocol/server/types/field/Field.md b/docs-archive/stardust-protocol/server/types/field/Field.md index e1c0514e..9da2d9ab 100644 --- a/docs-archive/stardust-protocol/server/types/field/Field.md +++ b/docs-archive/stardust-protocol/server/types/field/Field.md @@ -10,4 +10,4 @@ Returns the distance from `point` to the surface of the object, positive if the Returns the normal of `point` compared to the surface of the object. Normal always points toward object. ### `Vector3 closestPoint(string spacePath, Vector3 point)` -Returns the closest point from `point` to the surface of the object. Use this instead of `distance` and `normal` when best to limit IPC calls. \ No newline at end of file +Returns the closest point from `point` to the surface of the object. Use this instead of `distance` and `normal` when best to limit IPC calls. diff --git a/docs-archive/stardust-protocol/server/types/field/SphereField.md b/docs-archive/stardust-protocol/server/types/field/SphereField.md index 6ff4447b..dce90f81 100644 --- a/docs-archive/stardust-protocol/server/types/field/SphereField.md +++ b/docs-archive/stardust-protocol/server/types/field/SphereField.md @@ -4,4 +4,4 @@ This Field is in a sphere shape. ## Properties ### `setRadius(double size)` -Sets the radius of the sphere. \ No newline at end of file +Sets the radius of the sphere. diff --git a/docs-archive/stardust-protocol/server/types/input/InputHandler.md b/docs-archive/stardust-protocol/server/types/input/InputHandler.md index cbbcbf9a..d9548220 100755 --- a/docs-archive/stardust-protocol/server/types/input/InputHandler.md +++ b/docs-archive/stardust-protocol/server/types/input/InputHandler.md @@ -23,4 +23,4 @@ Get a list of all action names (human-readable). Set all the objects on this input handler to `actions`. ### `runAction(String actionName)` -Runs the action specififed by `actionName`. \ No newline at end of file +Runs the action specififed by `actionName`. diff --git a/docs-archive/stardust-protocol/server/types/input/InputMethod.md b/docs-archive/stardust-protocol/server/types/input/InputMethod.md index 713290c1..a614e43c 100755 --- a/docs-archive/stardust-protocol/server/types/input/InputMethod.md +++ b/docs-archive/stardust-protocol/server/types/input/InputMethod.md @@ -48,4 +48,4 @@ Standard supported datamap keys will be put in the individual type's documentati ### `modifyDatamap(Dictionary data)` -Merges the datamap of this [InputMethod](InputMethod) with `data`. Each key here will add to the datamap if not present and set the existing value if present. Any key not present in `data` will be unaffected. \ No newline at end of file +Merges the datamap of this [InputMethod](InputMethod) with `data`. Each key here will add to the datamap if not present and set the existing value if present. Any key not present in `data` will be unaffected. diff --git a/docs-archive/stardust-protocol/server/types/input/inputtypes/HandInput.md b/docs-archive/stardust-protocol/server/types/input/inputtypes/HandInput.md index a02afce9..c1cccd1e 100644 --- a/docs-archive/stardust-protocol/server/types/input/inputtypes/HandInput.md +++ b/docs-archive/stardust-protocol/server/types/input/inputtypes/HandInput.md @@ -1,4 +1,5 @@ # HandInput + ### Derived from [InputMethod](../InputMethod) A full 27-bone hand+forearm input with useful abstractions provided through the datamap. @@ -6,6 +7,7 @@ A full 27-bone hand+forearm input with useful abstractions provided through the The local space of a hand is where +Z is away from the palm, +Y is from the palm to the fingers, and +X is orthogonal and to the right. ## Serialization + | Key | Value Type | |-----------|--------------| | origin | `Vector3` | @@ -15,36 +17,39 @@ The local space of a hand is where +Z is away from the palm, +Y is from the palm ```js [ - thumb metacarpal, - thumb proximal, - thumb distal, - thumb tip, - index metacarpal, - index proximal, - index intermediate, - index distal, - index tip, - middle metacarpal, - middle proximal, - middle intermediate, - middle distal, - middle tip, - ring metacarpal, - ring proximal, - ring intermediate, - ring distal, - ring tip, - little metacarpal, - little proximal, - little intermediate, - little distal, - little tip + thumb metacarpal, + thumb proximal, + thumb distal, + thumb tip, + index metacarpal, + index proximal, + index intermediate, + index distal, + index tip, + middle metacarpal, + middle proximal, + middle intermediate, + middle distal, + middle tip, + ring metacarpal, + ring proximal, + ring intermediate, + ring distal, + ring tip, + little metacarpal, + little proximal, + little intermediate, + little distal, + little tip ] ``` + (This section is WIP) ## Datamap + ### Required + | Key | Value Type | Description | |-----------------|-----------------------------|--------------------------------------------------------------------| | confidence | `float` (range `0.0`-`1.0`) | How confident the hand tracker is of the pose of the hand | @@ -54,4 +59,5 @@ The local space of a hand is where +Z is away from the palm, +Y is from the palm | grabStrength | `float` (range `0.0`-`1.0`) | How much the hand is making a fist | ## Methods -**TODO**: Properly secured field distance calculation accessible to clients \ No newline at end of file + +**TODO**: Properly secured field distance calculation accessible to clients diff --git a/docusaurus.config.js b/docusaurus.config.js index dfc1a901..f0f72c3f 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -33,7 +33,7 @@ module.exports = { }, { type: 'doc', - docId: 'getting-started/overview', + docId: 'overview', position: 'left', label: 'Docs', }, diff --git a/sidebars.js b/sidebars.js index 7a0a3832..ddc2e7f8 100644 --- a/sidebars.js +++ b/sidebars.js @@ -1,12 +1,13 @@ /** - * Creating a sidebar enables you to: - - create an ordered group of docs - - render a sidebar for each doc of that group - - provide next/previous navigation + Creating a sidebar enables you to: + - create an ordered group of docs + - render a sidebar for each doc of that group + - provide next/previous navigation - The sidebars can be generated from the filesystem, or explicitly defined here. - Create as many sidebars as you want. + The sidebars can be generated from the filesystem, or explicitly defined here. + + Create as many sidebars as you want. */ module.exports = { diff --git a/src/css/custom.css b/src/css/custom.css index a1f77d98..0416897d 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -43,4 +43,4 @@ li.task-list-item > input[type="checkbox"] { .gallery { margin: 0 auto; max-width: 1250px; -} \ No newline at end of file +} diff --git a/src/pages/roadmap.md b/src/pages/roadmap.md index 0b5cf26f..26f0eb52 100644 --- a/src/pages/roadmap.md +++ b/src/pages/roadmap.md @@ -70,4 +70,4 @@ title: Roadmap - [ ] Panel Item UI - [ ] Flatland -More to come! \ No newline at end of file +More to come! diff --git a/static/CNAME b/static/CNAME index 4d2d3500..3c76cdec 100644 --- a/static/CNAME +++ b/static/CNAME @@ -1 +1 @@ -stardustxr.org \ No newline at end of file +stardustxr.org