Merge pull request #443 from status-im/feature/#441
Command list (#441)
This commit is contained in:
commit
887db6a1ab
|
@ -1,7 +1,8 @@
|
||||||
status.command({
|
status.command({
|
||||||
name: "location",
|
name: "location",
|
||||||
icon: "location",
|
icon: "location",
|
||||||
description: "Send location",
|
title: "Location",
|
||||||
|
description: "Share your location",
|
||||||
color: "#a187d5",
|
color: "#a187d5",
|
||||||
preview: function (params) {
|
preview: function (params) {
|
||||||
var text = status.components.text(
|
var text = status.components.text(
|
||||||
|
@ -52,7 +53,8 @@ function browseSuggestions(params) {
|
||||||
|
|
||||||
status.command({
|
status.command({
|
||||||
name: "browse",
|
name: "browse",
|
||||||
description: "browser",
|
title: "Browser",
|
||||||
|
description: "Launch the browser",
|
||||||
color: "#ffa500",
|
color: "#ffa500",
|
||||||
fullscreen: true,
|
fullscreen: true,
|
||||||
suggestionsTrigger: 'on-send',
|
suggestionsTrigger: 'on-send',
|
||||||
|
@ -121,7 +123,8 @@ var send = {
|
||||||
name: "send",
|
name: "send",
|
||||||
icon: "money_white",
|
icon: "money_white",
|
||||||
color: "#5fc48d",
|
color: "#5fc48d",
|
||||||
description: "Send transaction",
|
title: "Send ETH",
|
||||||
|
description: "Send a payment",
|
||||||
params: [{
|
params: [{
|
||||||
name: "amount",
|
name: "amount",
|
||||||
type: status.types.NUMBER
|
type: status.types.NUMBER
|
||||||
|
@ -141,8 +144,9 @@ status.response(send);
|
||||||
|
|
||||||
status.command({
|
status.command({
|
||||||
name: "request",
|
name: "request",
|
||||||
|
title: "Request ETH",
|
||||||
color: "#7099e6",
|
color: "#7099e6",
|
||||||
description: "Transaction request",
|
description: "Request a payment",
|
||||||
params: [{
|
params: [{
|
||||||
name: "amount",
|
name: "amount",
|
||||||
type: status.types.NUMBER
|
type: status.types.NUMBER
|
||||||
|
|
|
@ -100,7 +100,8 @@ function phoneSuggestions(params) {
|
||||||
var phoneConfig = {
|
var phoneConfig = {
|
||||||
name: "phone",
|
name: "phone",
|
||||||
icon: "phone_white",
|
icon: "phone_white",
|
||||||
description: "Send phone number",
|
title: "Send Phone Number",
|
||||||
|
description: "Find friends using your number",
|
||||||
color: "#5bb2a2",
|
color: "#5bb2a2",
|
||||||
params: [{
|
params: [{
|
||||||
name: "phone",
|
name: "phone",
|
||||||
|
@ -115,7 +116,8 @@ status.command(phoneConfig);
|
||||||
|
|
||||||
status.command({
|
status.command({
|
||||||
name: "help",
|
name: "help",
|
||||||
description: "Help",
|
title: "Help",
|
||||||
|
description: "Request help from Console",
|
||||||
color: "#7099e6",
|
color: "#7099e6",
|
||||||
params: [{
|
params: [{
|
||||||
name: "query",
|
name: "query",
|
||||||
|
|
|
@ -22,6 +22,7 @@ Command.prototype.param = function (parameter) {
|
||||||
|
|
||||||
Command.prototype.create = function (com) {
|
Command.prototype.create = function (com) {
|
||||||
this.name = com.name;
|
this.name = com.name;
|
||||||
|
this.title = com.title;
|
||||||
this.description = com.description;
|
this.description = com.description;
|
||||||
this.handler = com.handler;
|
this.handler = com.handler;
|
||||||
this["has-handler"] = com.handler != null;
|
this["has-handler"] = com.handler != null;
|
||||||
|
|
|
@ -13,7 +13,8 @@ function wallet(params) {
|
||||||
|
|
||||||
status.command({
|
status.command({
|
||||||
name: "browse",
|
name: "browse",
|
||||||
description: "Browse wallet",
|
title: "Browser",
|
||||||
|
description: "Launch the browser",
|
||||||
color: "#ffa500",
|
color: "#ffa500",
|
||||||
fullscreen: true,
|
fullscreen: true,
|
||||||
suggestionsTrigger: 'on-send',
|
suggestionsTrigger: 'on-send',
|
||||||
|
|
|
@ -41,7 +41,7 @@
|
||||||
"By console, today at 14:50"]]]])
|
"By console, today at 14:50"]]]])
|
||||||
|
|
||||||
(defn suggestion-list-item
|
(defn suggestion-list-item
|
||||||
[[command {:keys [description]
|
[[command {:keys [title description]
|
||||||
name :name
|
name :name
|
||||||
:as suggestion}]]
|
:as suggestion}]]
|
||||||
(let [label (str "!" name)]
|
(let [label (str "!" name)]
|
||||||
|
@ -51,7 +51,7 @@
|
||||||
[view st/suggestion-container
|
[view st/suggestion-container
|
||||||
[view st/suggestion-sub-container
|
[view st/suggestion-sub-container
|
||||||
[view st/command-description-container
|
[view st/command-description-container
|
||||||
[text {:style st/value-text} label]
|
[text {:style st/value-text} title]
|
||||||
[text {:style st/description-text} description]]
|
[text {:style st/description-text} description]]
|
||||||
[view st/command-label-container
|
[view st/command-label-container
|
||||||
[view (st/suggestion-background suggestion)
|
[view (st/suggestion-background suggestion)
|
||||||
|
|
Loading…
Reference in New Issue