Add Store support and unsigned app releases
This commit is contained in:
@@ -3,6 +3,59 @@
|
||||
export component AppIcon inherits Rectangle {
|
||||
in property <string> icon;
|
||||
in property <color> ink: #ffffff;
|
||||
// Store apps bring their own picture (app.toml: icon = "icon.png").
|
||||
in property <image> image;
|
||||
in property <bool> has-image: false;
|
||||
// No picture and no built-in icon: the app name's first letter.
|
||||
in property <string> letter;
|
||||
property <bool> builtin: root.icon == "netflex" || root.icon == "youtube" || root.icon == "airplay" || root.icon == "miracast" || root.icon == "settings" || root.icon == "store" || root.icon == "steam";
|
||||
|
||||
if root.has-image: Image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
source: root.image;
|
||||
image-fit: contain;
|
||||
}
|
||||
|
||||
if !root.has-image && !root.builtin: Text {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
horizontal-alignment: center;
|
||||
vertical-alignment: center;
|
||||
text: root.letter;
|
||||
font-size: root.height * 0.72;
|
||||
font-weight: 700;
|
||||
color: root.ink;
|
||||
}
|
||||
|
||||
if root.icon == "store": Rectangle {
|
||||
// App Store: a shopping bag with a handle.
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M6.5 11h19l-1.4 15a2.5 2.5 0 0 1-2.5 2.3H10.4a2.5 2.5 0 0 1-2.5-2.3z";
|
||||
fill: @linear-gradient(180deg, #8cc4ff 0%, #3d7fe0 100%);
|
||||
}
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M11.5 14V9.5a4.5 4.5 0 0 1 9 0V14";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.4px;
|
||||
stroke-line-cap: round;
|
||||
}
|
||||
}
|
||||
|
||||
if root.icon == "steam": Rectangle {
|
||||
// Steam mark: the piston and valve in a disc (Simple Icons, CC0).
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-x: -3; viewbox-y: -3;
|
||||
viewbox-width: 30; viewbox-height: 30;
|
||||
commands: "M11.979 0C5.678 0 .511 4.86.022 11.037l6.432 2.658c.545-.371 1.203-.59 1.912-.59.063 0 .125.004.188.006l2.861-4.142V8.91c0-2.495 2.028-4.524 4.524-4.524 2.494 0 4.524 2.031 4.524 4.527s-2.03 4.525-4.524 4.525h-.105l-4.076 2.911c0 .052.004.105.004.159 0 1.875-1.515 3.396-3.39 3.396-1.635 0-3.016-1.173-3.331-2.727L.436 15.27C1.862 20.307 6.486 24 11.979 24c6.627 0 11.999-5.373 11.999-12S18.605 0 11.979 0zM7.54 18.21l-1.473-.61c.262.543.714.999 1.314 1.25 1.297.539 2.793-.076 3.332-1.375.263-.63.264-1.319.005-1.949s-.75-1.121-1.377-1.383c-.624-.26-1.29-.249-1.878-.03l1.523.63c.956.4 1.409 1.5 1.009 2.455-.397.957-1.497 1.41-2.454 1.012H7.54zm11.415-9.303c0-1.662-1.353-3.015-3.015-3.015-1.665 0-3.015 1.353-3.015 3.015 0 1.665 1.35 3.015 3.015 3.015 1.663 0 3.015-1.35 3.015-3.015zm-5.273-.005c0-1.252 1.013-2.266 2.265-2.266 1.249 0 2.266 1.014 2.266 2.266 0 1.251-1.017 2.265-2.266 2.265-1.253 0-2.265-1.014-2.265-2.265z";
|
||||
fill: @linear-gradient(160deg, #ffffff 0%, #c7e4f8 100%);
|
||||
}
|
||||
}
|
||||
|
||||
if root.icon == "netflex": Rectangle {
|
||||
// Netflex mark: mirrored "N" in three ribbons (from netflex/apps/web/public/favicon.svg).
|
||||
@@ -107,7 +160,7 @@ export component AppIcon inherits Rectangle {
|
||||
}
|
||||
}
|
||||
|
||||
// SmartFox brand mark: a geometric fox head.
|
||||
// Fennec OS brand mark: a geometric fox head.
|
||||
export component FoxMark inherits Rectangle {
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
@@ -293,3 +346,273 @@ export component PowerIcon inherits Rectangle {
|
||||
stroke-line-cap: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component AudioIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M5 12h6l7-6v20l-7-6H5zM22 12a6 6 0 0 1 0 8M25 8a11 11 0 0 1 0 16";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.2px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
}
|
||||
|
||||
// Siri Remote, front view (status capsule, facts).
|
||||
export component RemoteIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M12.5 3h7a3 3 0 0 1 3 3v20a3 3 0 0 1-3 3h-7a3 3 0 0 1-3-3V6a3 3 0 0 1 3-3z";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.2px;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M12.6 10.5a3.4 3.4 0 1 0 6.8 0a3.4 3.4 0 1 0-6.8 0zM13.5 18.5a1.3 1.3 0 1 0 2.6 0a1.3 1.3 0 1 0-2.6 0zM15.9 18.5a1.3 1.3 0 1 0 2.6 0a1.3 1.3 0 1 0-2.6 0z";
|
||||
fill: root.ink;
|
||||
}
|
||||
}
|
||||
|
||||
// Wired network (ethernet plug).
|
||||
export component WiredIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M9 6h14a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-3v4h-8v-4H9a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2zM16 23v5M12.5 10.5v3M16 10.5v3M19.5 10.5v3";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.2px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
}
|
||||
|
||||
// Cast from a phone: screen with broadcast arcs in the corner.
|
||||
export component CastIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M4 11V8.5A2.5 2.5 0 0 1 6.5 6h19A2.5 2.5 0 0 1 28 8.5v15a2.5 2.5 0 0 1-2.5 2.5H17M4 16.5a9.5 9.5 0 0 1 9.5 9.5M4 21.5a4.5 4.5 0 0 1 4.5 4.5";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.2px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M3 26a1.5 1.5 0 1 0 3 0a1.5 1.5 0 1 0-3 0z";
|
||||
fill: root.ink;
|
||||
}
|
||||
}
|
||||
|
||||
// Home media server.
|
||||
export component ServerIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M7 5h18a2 2 0 0 1 2 2v5a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2zM7 18h18a2 2 0 0 1 2 2v5a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-5a2 2 0 0 1 2-2z";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.2px;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M9.5 9.5a1.4 1.4 0 1 0 2.8 0a1.4 1.4 0 1 0-2.8 0zM9.5 22.5a1.4 1.4 0 1 0 2.8 0a1.4 1.4 0 1 0-2.8 0z";
|
||||
fill: root.ink;
|
||||
}
|
||||
}
|
||||
|
||||
export component CheckIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M7 16.5l6 6L25.5 10";
|
||||
stroke: root.ink;
|
||||
stroke-width: 3px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component AlertIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M16 8v10";
|
||||
stroke: root.ink;
|
||||
stroke-width: 3px;
|
||||
stroke-line-cap: round;
|
||||
}
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M14.2 24a1.8 1.8 0 1 0 3.6 0a1.8 1.8 0 1 0-3.6 0z";
|
||||
fill: root.ink;
|
||||
}
|
||||
}
|
||||
|
||||
export component ChevronIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M12 7l9 9-9 9";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.6px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
}
|
||||
|
||||
// Remote buttons in the pairing drawing.
|
||||
export component BackGlyph inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M19 8l-8 8 8 8";
|
||||
stroke: root.ink;
|
||||
stroke-width: 3px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component TvGlyph inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M7.5 8h17a1.5 1.5 0 0 1 1.5 1.5v11a1.5 1.5 0 0 1-1.5 1.5h-17A1.5 1.5 0 0 1 6 20.5v-11A1.5 1.5 0 0 1 7.5 8zM12 25.5h8";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.6px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component PlayPauseGlyph inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M6 9.5v13l9-6.5z";
|
||||
fill: root.ink;
|
||||
}
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M19.5 10v12M25 10v12";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.8px;
|
||||
stroke-line-cap: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component MuteGlyph inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M5 12.5h4.5L16 7v18l-6.5-5.5H5z";
|
||||
fill: root.ink;
|
||||
}
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M20.5 12.5l7 7M27.5 12.5l-7 7";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.6px;
|
||||
stroke-line-cap: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component PlusGlyph inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M16 8v16M8 16h16";
|
||||
stroke: root.ink;
|
||||
stroke-width: 3px;
|
||||
stroke-line-cap: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component MinusGlyph inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M8 16h16";
|
||||
stroke: root.ink;
|
||||
stroke-width: 3px;
|
||||
stroke-line-cap: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component PowerGlyph inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M10.3 9.6a9 9 0 1 0 11.4 0M16 5.5v10";
|
||||
stroke: root.ink;
|
||||
stroke-width: 3px;
|
||||
stroke-line-cap: round;
|
||||
}
|
||||
}
|
||||
|
||||
// One icon by name, for data-driven rows (home screen facts).
|
||||
export component NamedIcon inherits Rectangle {
|
||||
in property <string> name;
|
||||
in property <color> ink: #ffffff;
|
||||
if root.name == "remote": RemoteIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
if root.name == "wifi": WifiIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
if root.name == "wired": WiredIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
if root.name == "display": DisplayIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
if root.name == "cast": CastIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
if root.name == "server": ServerIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
if root.name == "check": CheckIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
if root.name == "alert": AlertIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
if root.name == "bluetooth": BluetoothIcon { width: 100%; height: 100%; ink: root.ink; }
|
||||
}
|
||||
|
||||
// Store screen categories (settings.slint NavIcon 5..7).
|
||||
export component StoreIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M6.5 11h19l-1.4 15a2.5 2.5 0 0 1-2.5 2.3H10.4a2.5 2.5 0 0 1-2.5-2.3zM11.5 14V9.5a4.5 4.5 0 0 1 9 0V14";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.2px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
}
|
||||
|
||||
export component LinkIcon inherits Rectangle {
|
||||
in property <color> ink: #ffffff;
|
||||
Path {
|
||||
width: 100%; height: 100%;
|
||||
viewbox-width: 32; viewbox-height: 32;
|
||||
commands: "M14 18a5 5 0 0 0 7.1 0l4-4a5 5 0 0 0-7.1-7.1l-1.5 1.5M18 14a5 5 0 0 0-7.1 0l-4 4a5 5 0 0 0 7.1 7.1l1.5-1.5";
|
||||
stroke: root.ink;
|
||||
stroke-width: 2.4px;
|
||||
stroke-line-cap: round;
|
||||
stroke-line-join: round;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user