omarchy-ui 0.0.5-x86_64-linux → 0.0.6-x86_64-linux
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/App.qml +3 -4
- data/BarWidget.qml +2 -3
- data/Panel.qml +3 -4
- data/README.md +17 -15
- data/Service.qml +61 -3
- data/ZuiRenderer.qml +37 -0
- data/lib/omarchy_ui/runtime.rb +10 -9
- data/lib/omarchy_ui.rb +1 -1
- metadata +4 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 8c8e67a6ee733ab185881c3af8614d428d5888fcea3fed015780ccc4bae6a3b5
|
|
4
|
+
data.tar.gz: 648c98f47aea9d30e857809a65052bdb2ca374ecaebc122a3ea192b99aa2b815
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 5f7664f1dafd992a22872bc029e8c48a242452ad5a8df9185a2aa0707b94b14df8724bd2e8c4fe3bd79afedeaf957e838fb1e27ecabb9467ba0ec41806e8f6d8
|
|
7
|
+
data.tar.gz: 97ec7a87a20e40653d8247cf69fd2534febb44b89ea7601355ada885d5f1978753332418ae756c9cf2e934a5534d108f43a850eca1c2ef3dc1c741435243d4ea
|
data/App.qml
CHANGED
|
@@ -2,7 +2,6 @@ import QtQuick
|
|
|
2
2
|
import Quickshell
|
|
3
3
|
import qs.Commons
|
|
4
4
|
import qs.Ui as OmarchyUi
|
|
5
|
-
import "Theme" as ZuiTheme
|
|
6
5
|
|
|
7
6
|
ShellRoot {
|
|
8
7
|
id: root
|
|
@@ -83,7 +82,7 @@ ShellRoot {
|
|
|
83
82
|
}
|
|
84
83
|
}
|
|
85
84
|
|
|
86
|
-
|
|
85
|
+
ZuiRenderer {
|
|
87
86
|
id: renderer
|
|
88
87
|
anchors {
|
|
89
88
|
left: parent.left
|
|
@@ -92,7 +91,7 @@ ShellRoot {
|
|
|
92
91
|
bottom: parent.bottom
|
|
93
92
|
margins: Style.space(24)
|
|
94
93
|
}
|
|
95
|
-
visible:
|
|
94
|
+
visible: renderReady
|
|
96
95
|
bridge: service
|
|
97
96
|
surfaceName: root.activeSurface
|
|
98
97
|
controlId: service.rootId(surfaceName)
|
|
@@ -104,7 +103,7 @@ ShellRoot {
|
|
|
104
103
|
anchors.centerIn: parent
|
|
105
104
|
visible: !renderer.visible
|
|
106
105
|
text: service.lastError !== "" ? service.lastError
|
|
107
|
-
:
|
|
106
|
+
: "Starting Ruby UI with Zui…"
|
|
108
107
|
color: Color.foreground
|
|
109
108
|
font.family: Style.font.family
|
|
110
109
|
font.pixelSize: Style.font.body
|
data/BarWidget.qml
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import QtQuick
|
|
2
2
|
import qs.Commons
|
|
3
3
|
import qs.Ui
|
|
4
|
-
import "Theme" as ZuiTheme
|
|
5
4
|
|
|
6
5
|
BarWidget {
|
|
7
6
|
id: root
|
|
@@ -17,10 +16,10 @@ BarWidget {
|
|
|
17
16
|
implicitWidth: Math.max(Style.bar.iconSlot, renderer.implicitWidth + Style.space(12))
|
|
18
17
|
implicitHeight: barSize
|
|
19
18
|
|
|
20
|
-
|
|
19
|
+
ZuiRenderer {
|
|
21
20
|
id: renderer
|
|
22
21
|
anchors.centerIn: parent
|
|
23
|
-
visible:
|
|
22
|
+
visible: renderReady
|
|
24
23
|
bridge: root.rubyService
|
|
25
24
|
surfaceName: root.surfaceName
|
|
26
25
|
controlId: root.rootControlId
|
data/Panel.qml
CHANGED
|
@@ -3,7 +3,6 @@ import Quickshell
|
|
|
3
3
|
import Quickshell.Wayland
|
|
4
4
|
import qs.Commons
|
|
5
5
|
import qs.Ui as OmarchyUi
|
|
6
|
-
import "Theme" as ZuiTheme
|
|
7
6
|
|
|
8
7
|
Item {
|
|
9
8
|
id: root
|
|
@@ -78,10 +77,10 @@ Item {
|
|
|
78
77
|
onClicked: {}
|
|
79
78
|
}
|
|
80
79
|
|
|
81
|
-
|
|
80
|
+
ZuiRenderer {
|
|
82
81
|
id: renderer
|
|
83
82
|
anchors.centerIn: parent
|
|
84
|
-
visible:
|
|
83
|
+
visible: renderReady
|
|
85
84
|
bridge: root.service
|
|
86
85
|
surfaceName: root.surfaceName
|
|
87
86
|
controlId: root.rootControlId
|
|
@@ -98,7 +97,7 @@ Item {
|
|
|
98
97
|
anchors.horizontalCenter: parent.horizontalCenter
|
|
99
98
|
text: root.service && root.service.lastError !== ""
|
|
100
99
|
? root.service.lastError
|
|
101
|
-
:
|
|
100
|
+
: "Starting Ruby UI with Zui…"
|
|
102
101
|
color: Color.foreground
|
|
103
102
|
font.family: Style.font.family
|
|
104
103
|
font.pixelSize: Style.font.body
|
data/README.md
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
</p>
|
|
11
11
|
|
|
12
12
|
<p align="center">
|
|
13
|
-
<img alt="Omarchy UI 0.0.
|
|
13
|
+
<img alt="Omarchy UI 0.0.6" src="https://img.shields.io/badge/Omarchy_UI-0.0.6-b7ff5a?style=flat-square&labelColor=111711">
|
|
14
14
|
<img alt="Ruby 3.1 or newer" src="https://img.shields.io/badge/Ruby-3.1%2B-cc342d?style=flat-square&logo=ruby&logoColor=white">
|
|
15
15
|
<img alt="Zui 0.0.10" src="https://img.shields.io/badge/Zui-0.0.10-7ee14b?style=flat-square&labelColor=111711">
|
|
16
16
|
<img alt="241 components" src="https://img.shields.io/badge/components-241-75d943?style=flat-square&labelColor=111711">
|
|
@@ -63,9 +63,11 @@ and the Omarchy adapter.
|
|
|
63
63
|
- Ruby 3.1 or newer while installing the gem and developing applications;
|
|
64
64
|
- optional Qt modules for components that use features such as Quick 3D or Multimedia.
|
|
65
65
|
|
|
66
|
-
The finished Omarchy bundle includes the
|
|
67
|
-
|
|
68
|
-
|
|
66
|
+
The finished Omarchy bundle includes the Omarchy adapter and mruby executable. Shared renderers,
|
|
67
|
+
controls, theme, and fonts stay in the compatible Zui gem instead of being duplicated into every
|
|
68
|
+
plugin. The destination therefore needs Ruby and `omarchy-ui` installed. A component fails with an
|
|
69
|
+
explicit error when its gem, required Qt module, or resource is unavailable; Omarchy UI never
|
|
70
|
+
substitutes a different component.
|
|
69
71
|
|
|
70
72
|
## Quick start
|
|
71
73
|
|
|
@@ -101,7 +103,7 @@ counter/
|
|
|
101
103
|
omarchy_ui run main.rb
|
|
102
104
|
```
|
|
103
105
|
|
|
104
|
-
`run` bundles the project's Ruby entry point, prepares the
|
|
106
|
+
`run` bundles the project's Ruby entry point, prepares the Omarchy host, resolves the exact Zui gem,
|
|
105
107
|
then launches it through Quickshell.
|
|
106
108
|
|
|
107
109
|
## Application model
|
|
@@ -333,7 +335,7 @@ omarchy_ui <command> [arguments]
|
|
|
333
335
|
| --- | --- | --- |
|
|
334
336
|
| `omarchy_ui new NAME` | One application name | Creates a new application directory using a URL-safe form of the name |
|
|
335
337
|
| `omarchy_ui run FILE` | One Ruby entry point | Runs an application through the Omarchy/Quickshell host |
|
|
336
|
-
| `omarchy_ui bundle [DIRECTORY]` | Zero or one project directory | Creates `dist/<project-name>` with the application, adapter,
|
|
338
|
+
| `omarchy_ui bundle [DIRECTORY]` | Zero or one project directory | Creates `dist/<project-name>` with the application, Omarchy adapter, and runtime; shared UI comes from Zui |
|
|
337
339
|
| `omarchy_ui validate [DIRECTORY]` | Zero or one plugin directory | Stages the complete plugin and delegates validation to `omarchy plugin validate` |
|
|
338
340
|
| `omarchy_ui push [DIRECTORY]` | Optional `--no-enable` and `--no-restart` | Atomically installs and activates a validated plugin |
|
|
339
341
|
| `omarchy_ui version` | None | Prints the installed Omarchy UI version |
|
|
@@ -360,9 +362,7 @@ dist/my-application/
|
|
|
360
362
|
├── Service.qml # process and surface bridge
|
|
361
363
|
├── Panel.qml # shell panel adapter
|
|
362
364
|
├── BarWidget.qml # shell bar adapter
|
|
363
|
-
├──
|
|
364
|
-
├── Components/ # complete native catalog
|
|
365
|
-
├── Controls/ Theme/ Fonts/ # Zui presentation modules
|
|
365
|
+
├── ZuiRenderer.qml # resolves Zui's shared protocol renderer
|
|
366
366
|
├── Commons@ Ui@ # links to Omarchy's shell modules
|
|
367
367
|
├── omarchy-ui-runtime # embedded mruby executable
|
|
368
368
|
├── omarchy-ui-runtime.sha256
|
|
@@ -371,8 +371,10 @@ dist/my-application/
|
|
|
371
371
|
```
|
|
372
372
|
|
|
373
373
|
Plugin bundles use the same runtime package and are validated against their manifest before the
|
|
374
|
-
bundle command succeeds. Generated packages exclude `.git`, previous `dist` output,
|
|
375
|
-
adapter/runtime files.
|
|
374
|
+
bundle command succeeds. Generated packages exclude `.git`, previous `dist` output, stale
|
|
375
|
+
adapter/runtime files, and every Zui-owned QML directory. Install `omarchy-ui` on the destination so
|
|
376
|
+
RubyGems supplies the exact Zui 0.0.10 catalog once for every plugin. The exact pin intentionally
|
|
377
|
+
matches the Zui core embedded in the deterministic mruby runtime.
|
|
376
378
|
|
|
377
379
|
## Component catalog
|
|
378
380
|
|
|
@@ -459,10 +461,10 @@ The dependency direction is deliberate:
|
|
|
459
461
|
integration, plugin lifecycle commands, and Omarchy packaging.
|
|
460
462
|
- **Applications own** Ruby source, assets, state, behavior, and reusable UI modules.
|
|
461
463
|
|
|
462
|
-
At
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
boundary](docs/qml-support.md).
|
|
464
|
+
At runtime, the adapter locates the compatible Zui gem and loads its protocol renderer, components,
|
|
465
|
+
controls, theme, and fonts directly from `Zui::FRAMEWORK_ROOT`. Bundle, validation, and push install
|
|
466
|
+
only the Omarchy host files and never copy Zui component implementations into an application or
|
|
467
|
+
plugin. Read the full [QML ownership and adapter boundary](docs/qml-support.md).
|
|
466
468
|
|
|
467
469
|
## Runtime integrity
|
|
468
470
|
|
data/Service.qml
CHANGED
|
@@ -14,6 +14,10 @@ Item {
|
|
|
14
14
|
readonly property string rubyProgram: pluginDir + "/main.rb"
|
|
15
15
|
property string program: ""
|
|
16
16
|
readonly property string effectiveRubyProgram: program !== "" ? program : rubyProgram
|
|
17
|
+
readonly property string requiredZuiVersion: "0.0.10"
|
|
18
|
+
property string zuiRoot: ""
|
|
19
|
+
property string zuiVersion: ""
|
|
20
|
+
readonly property bool zuiReady: zuiRoot !== ""
|
|
17
21
|
|
|
18
22
|
property bool ready: false
|
|
19
23
|
property bool stopping: false
|
|
@@ -414,7 +418,7 @@ Item {
|
|
|
414
418
|
|
|
415
419
|
function componentSource(typeName) {
|
|
416
420
|
var definition = componentDefinitions[String(typeName || "")]
|
|
417
|
-
return definition ?
|
|
421
|
+
return definition && zuiReady ? zuiRoot + "/Components/Builtins/" + definition.qml : ""
|
|
418
422
|
}
|
|
419
423
|
|
|
420
424
|
function componentDefinition(typeName) {
|
|
@@ -442,7 +446,7 @@ Item {
|
|
|
442
446
|
}
|
|
443
447
|
|
|
444
448
|
function startRuby() {
|
|
445
|
-
if (stopping || pluginDir === "" || rubyProcess.running) return
|
|
449
|
+
if (stopping || pluginDir === "" || !zuiReady || rubyProcess.running) return
|
|
446
450
|
var configuredRuntime = String(Quickshell.env("OMARCHY_UI_RUNTIME") || "")
|
|
447
451
|
rubyProcess.command = [
|
|
448
452
|
configuredRuntime !== "" ? configuredRuntime : pluginDir + "/omarchy-ui-runtime",
|
|
@@ -452,14 +456,68 @@ Item {
|
|
|
452
456
|
rubyProcess.running = true
|
|
453
457
|
}
|
|
454
458
|
|
|
455
|
-
|
|
459
|
+
function locateZui() {
|
|
460
|
+
if (stopping || pluginDir === "" || zuiReady || zuiLocator.running) return
|
|
461
|
+
zuiLocator.command = [
|
|
462
|
+
"ruby", "-e",
|
|
463
|
+
'require "json"; gem "zui", "= ' + requiredZuiVersion
|
|
464
|
+
+ '"; require "zui"; STDOUT.write(JSON.generate({root: Zui::FRAMEWORK_ROOT, version: Zui::VERSION}))'
|
|
465
|
+
]
|
|
466
|
+
zuiLocator.running = true
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
onPluginDirChanged: {
|
|
470
|
+
zuiRoot = ""
|
|
471
|
+
zuiVersion = ""
|
|
472
|
+
Qt.callLater(locateZui)
|
|
473
|
+
}
|
|
474
|
+
|
|
475
|
+
Component.onCompleted: Qt.callLater(locateZui)
|
|
456
476
|
|
|
457
477
|
Component.onDestruction: {
|
|
458
478
|
stopping = true
|
|
459
479
|
restartTimer.stop()
|
|
480
|
+
if (zuiLocator.running) zuiLocator.running = false
|
|
460
481
|
if (rubyProcess.running) rubyProcess.running = false
|
|
461
482
|
}
|
|
462
483
|
|
|
484
|
+
Process {
|
|
485
|
+
id: zuiLocator
|
|
486
|
+
|
|
487
|
+
stdout: StdioCollector {
|
|
488
|
+
id: zuiLocatorOutput
|
|
489
|
+
waitForEnd: true
|
|
490
|
+
}
|
|
491
|
+
|
|
492
|
+
stderr: StdioCollector {
|
|
493
|
+
id: zuiLocatorError
|
|
494
|
+
waitForEnd: true
|
|
495
|
+
}
|
|
496
|
+
|
|
497
|
+
onExited: function(exitCode) {
|
|
498
|
+
if (root.stopping || root.pluginDir === "") return
|
|
499
|
+
var detail = String(zuiLocatorError.text || "").trim()
|
|
500
|
+
if (exitCode !== 0) {
|
|
501
|
+
root.lastError = "Zui " + root.requiredZuiVersion
|
|
502
|
+
+ " is required from the omarchy-ui gem"
|
|
503
|
+
+ (detail !== "" ? ": " + detail.slice(0, 240) : "")
|
|
504
|
+
return
|
|
505
|
+
}
|
|
506
|
+
try {
|
|
507
|
+
var located = JSON.parse(String(zuiLocatorOutput.text || ""))
|
|
508
|
+
if (!located || typeof located.root !== "string" || located.root[0] !== "/"
|
|
509
|
+
|| String(located.version || "") !== root.requiredZuiVersion)
|
|
510
|
+
throw new Error("invalid Zui gem location")
|
|
511
|
+
root.zuiRoot = String(located.root)
|
|
512
|
+
root.zuiVersion = String(located.version)
|
|
513
|
+
root.lastError = ""
|
|
514
|
+
root.startRuby()
|
|
515
|
+
} catch (error) {
|
|
516
|
+
root.lastError = "Could not locate Zui " + root.requiredZuiVersion + " from RubyGems"
|
|
517
|
+
}
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
|
|
463
521
|
Process {
|
|
464
522
|
id: rubyProcess
|
|
465
523
|
stdinEnabled: true
|
data/ZuiRenderer.qml
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import QtQuick
|
|
2
|
+
|
|
3
|
+
Loader {
|
|
4
|
+
id: root
|
|
5
|
+
|
|
6
|
+
property var bridge: null
|
|
7
|
+
property string surfaceName: ""
|
|
8
|
+
property string controlId: ""
|
|
9
|
+
property color foreground: "white"
|
|
10
|
+
property string fontFamily: ""
|
|
11
|
+
readonly property bool renderReady: status === Loader.Ready && item !== null
|
|
12
|
+
&& String(item.iconFontFamily || "") !== ""
|
|
13
|
+
&& String(item.brandIconFontFamily || "") !== ""
|
|
14
|
+
|
|
15
|
+
active: bridge !== null && bridge.zuiReady && controlId !== ""
|
|
16
|
+
source: active ? bridge.zuiRoot + "/ControlNode.qml" : ""
|
|
17
|
+
|
|
18
|
+
function syncRenderer() {
|
|
19
|
+
if (!item) return
|
|
20
|
+
item.bridge = bridge
|
|
21
|
+
item.surfaceName = surfaceName
|
|
22
|
+
item.controlId = controlId
|
|
23
|
+
item.foreground = foreground
|
|
24
|
+
item.fontFamily = fontFamily
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
onLoaded: syncRenderer()
|
|
28
|
+
onBridgeChanged: syncRenderer()
|
|
29
|
+
onSurfaceNameChanged: syncRenderer()
|
|
30
|
+
onControlIdChanged: syncRenderer()
|
|
31
|
+
onForegroundChanged: syncRenderer()
|
|
32
|
+
onFontFamilyChanged: syncRenderer()
|
|
33
|
+
onStatusChanged: {
|
|
34
|
+
if (status === Loader.Error && bridge)
|
|
35
|
+
bridge.lastError = "Could not load Zui " + bridge.requiredZuiVersion + " renderer from its gem"
|
|
36
|
+
}
|
|
37
|
+
}
|
data/lib/omarchy_ui/runtime.rb
CHANGED
|
@@ -7,13 +7,13 @@ module OmarchyUI
|
|
|
7
7
|
module_function
|
|
8
8
|
|
|
9
9
|
BUNDLED = File.expand_path("../../vendor/runtime/x86_64-linux/omarchy-ui-runtime", __dir__)
|
|
10
|
-
ADAPTER_FILES = %w[Service.qml Panel.qml BarWidget.qml App.qml].freeze
|
|
11
|
-
|
|
12
|
-
FILES =
|
|
10
|
+
ADAPTER_FILES = %w[Service.qml Panel.qml BarWidget.qml App.qml ZuiRenderer.qml].freeze
|
|
11
|
+
ZUI_GENERATED_ENTRIES = %w[Desktop.qml ControlNode.qml Components Controls Theme Fonts].freeze
|
|
12
|
+
FILES = ADAPTER_FILES.freeze
|
|
13
13
|
AUDIT_FILES = %w[
|
|
14
14
|
omarchy-ui-runtime.sha256 runtime-provenance.json RUNTIME_PROVENANCE.md
|
|
15
15
|
].freeze
|
|
16
|
-
GENERATED_ENTRIES = (ADAPTER_FILES +
|
|
16
|
+
GENERATED_ENTRIES = (ADAPTER_FILES + ZUI_GENERATED_ENTRIES + %w[omarchy-ui-runtime]).freeze
|
|
17
17
|
|
|
18
18
|
def executable
|
|
19
19
|
override = ENV["OMARCHY_UI_RUNTIME"]
|
|
@@ -36,8 +36,11 @@ module OmarchyUI
|
|
|
36
36
|
end
|
|
37
37
|
|
|
38
38
|
def install_package(path, framework_root: FRAMEWORK_ROOT)
|
|
39
|
-
|
|
40
|
-
|
|
39
|
+
FileUtils.mkdir_p(path)
|
|
40
|
+
ZUI_GENERATED_ENTRIES.each do |entry|
|
|
41
|
+
generated = File.join(path, entry)
|
|
42
|
+
File.directory?(generated) ? FileUtils.remove_entry(generated) : FileUtils.rm_f(generated)
|
|
43
|
+
end
|
|
41
44
|
ADAPTER_FILES.each do |file|
|
|
42
45
|
FileUtils.cp(File.join(framework_root, file), File.join(path, file))
|
|
43
46
|
end
|
|
@@ -55,9 +58,7 @@ module OmarchyUI
|
|
|
55
58
|
end
|
|
56
59
|
|
|
57
60
|
def install_components(path, **)
|
|
58
|
-
|
|
59
|
-
FileUtils.rm_f(File.join(path, "Desktop.qml"))
|
|
60
|
-
path
|
|
61
|
+
install_package(path)
|
|
61
62
|
end
|
|
62
63
|
end
|
|
63
64
|
end
|
data/lib/omarchy_ui.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: omarchy-ui
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.6
|
|
5
5
|
platform: x86_64-linux
|
|
6
6
|
authors:
|
|
7
7
|
- Adam Moussa Ali
|
|
@@ -13,14 +13,14 @@ dependencies:
|
|
|
13
13
|
name: zui
|
|
14
14
|
requirement: !ruby/object:Gem::Requirement
|
|
15
15
|
requirements:
|
|
16
|
-
- -
|
|
16
|
+
- - '='
|
|
17
17
|
- !ruby/object:Gem::Version
|
|
18
18
|
version: 0.0.10
|
|
19
19
|
type: :runtime
|
|
20
20
|
prerelease: false
|
|
21
21
|
version_requirements: !ruby/object:Gem::Requirement
|
|
22
22
|
requirements:
|
|
23
|
-
- -
|
|
23
|
+
- - '='
|
|
24
24
|
- !ruby/object:Gem::Version
|
|
25
25
|
version: 0.0.10
|
|
26
26
|
description: The Omarchy adapter for the platform-neutral Zui desktop framework.
|
|
@@ -35,6 +35,7 @@ files:
|
|
|
35
35
|
- Panel.qml
|
|
36
36
|
- README.md
|
|
37
37
|
- Service.qml
|
|
38
|
+
- ZuiRenderer.qml
|
|
38
39
|
- bin/omarchy_ui
|
|
39
40
|
- lib/omarchy_ui.rb
|
|
40
41
|
- lib/omarchy_ui/cli.rb
|