diff options
Diffstat (limited to 'node_modules/montage/ui/popup')
4 files changed, 103 insertions, 100 deletions
diff --git a/node_modules/montage/ui/popup/alert.reel/alert.html b/node_modules/montage/ui/popup/alert.reel/alert.html index cb4ef751..40b0d2d5 100755 --- a/node_modules/montage/ui/popup/alert.reel/alert.html +++ b/node_modules/montage/ui/popup/alert.reel/alert.html | |||
@@ -8,8 +8,8 @@ | |||
8 | <head> | 8 | <head> |
9 | <meta http-equiv="content-type" content="text/html; charset=utf-8"/> | 9 | <meta http-equiv="content-type" content="text/html; charset=utf-8"/> |
10 | <link rel="stylesheet" type="text/css" href="alert.css"> | 10 | <link rel="stylesheet" type="text/css" href="alert.css"> |
11 | <script type="text/montage-serialization"> | 11 | <script type="text/montage-serialization">{ |
12 | { | 12 | |
13 | "dynamictext1": { | 13 | "dynamictext1": { |
14 | "module": "montage/ui/dynamic-text.reel", | 14 | "module": "montage/ui/dynamic-text.reel", |
15 | "name": "DynamicText", | 15 | "name": "DynamicText", |
@@ -19,13 +19,7 @@ | |||
19 | } | 19 | } |
20 | }, | 20 | }, |
21 | "bindings": { | 21 | "bindings": { |
22 | "value": { | 22 | "value": {"<-": "@owner.title"} |
23 | "boundObject": { | ||
24 | "@": "owner" | ||
25 | }, | ||
26 | "boundObjectPropertyPath": "title", | ||
27 | "oneway": true | ||
28 | } | ||
29 | } | 23 | } |
30 | }, | 24 | }, |
31 | "dynamictext2": { | 25 | "dynamictext2": { |
@@ -37,13 +31,7 @@ | |||
37 | } | 31 | } |
38 | }, | 32 | }, |
39 | "bindings": { | 33 | "bindings": { |
40 | "value": { | 34 | "value": {"<-": "@owner.msg"} |
41 | "boundObject": { | ||
42 | "@": "owner" | ||
43 | }, | ||
44 | "boundObjectPropertyPath": "msg", | ||
45 | "oneway": true | ||
46 | } | ||
47 | } | 35 | } |
48 | }, | 36 | }, |
49 | "dynamictext3": { | 37 | "dynamictext3": { |
@@ -55,13 +43,7 @@ | |||
55 | } | 43 | } |
56 | }, | 44 | }, |
57 | "bindings": { | 45 | "bindings": { |
58 | "value": { | 46 | "value": {"<-": "@owner.details"} |
59 | "boundObject": { | ||
60 | "@": "owner" | ||
61 | }, | ||
62 | "boundObjectPropertyPath": "details", | ||
63 | "oneway": true | ||
64 | } | ||
65 | } | 47 | } |
66 | }, | 48 | }, |
67 | "button1": { | 49 | "button1": { |
@@ -91,8 +73,8 @@ | |||
91 | } | 73 | } |
92 | } | 74 | } |
93 | } | 75 | } |
94 | } | 76 | |
95 | </script> | 77 | }</script> |
96 | 78 | ||
97 | 79 | ||
98 | </head> | 80 | </head> |
diff --git a/node_modules/montage/ui/popup/confirm.reel/confirm.html b/node_modules/montage/ui/popup/confirm.reel/confirm.html index 63b521bd..5762f1ad 100755 --- a/node_modules/montage/ui/popup/confirm.reel/confirm.html +++ b/node_modules/montage/ui/popup/confirm.reel/confirm.html | |||
@@ -8,8 +8,8 @@ | |||
8 | <head> | 8 | <head> |
9 | <meta http-equiv="content-type" content="text/html; charset=utf-8"/> | 9 | <meta http-equiv="content-type" content="text/html; charset=utf-8"/> |
10 | <link rel="stylesheet" type="text/css" href="confirm.css"> | 10 | <link rel="stylesheet" type="text/css" href="confirm.css"> |
11 | <script type="text/montage-serialization"> | 11 | <script type="text/montage-serialization">{ |
12 | { | 12 | |
13 | "dynamictext1": { | 13 | "dynamictext1": { |
14 | "module": "montage/ui/dynamic-text.reel", | 14 | "module": "montage/ui/dynamic-text.reel", |
15 | "name": "DynamicText", | 15 | "name": "DynamicText", |
@@ -19,13 +19,7 @@ | |||
19 | } | 19 | } |
20 | }, | 20 | }, |
21 | "bindings": { | 21 | "bindings": { |
22 | "value": { | 22 | "value": {"<-": "@owner.msg"} |
23 | "boundObject": { | ||
24 | "@": "owner" | ||
25 | }, | ||
26 | "boundObjectPropertyPath": "msg", | ||
27 | "oneway": true | ||
28 | } | ||
29 | } | 23 | } |
30 | }, | 24 | }, |
31 | "button1": { | 25 | "button1": { |
@@ -38,13 +32,7 @@ | |||
38 | } | 32 | } |
39 | }, | 33 | }, |
40 | "bindings": { | 34 | "bindings": { |
41 | "value": { | 35 | "value": {"<-": "@owner.okLabel"} |
42 | "boundObject": { | ||
43 | "@": "owner" | ||
44 | }, | ||
45 | "boundObjectPropertyPath": "okLabel", | ||
46 | "oneway": true | ||
47 | } | ||
48 | }, | 36 | }, |
49 | "listeners": [ | 37 | "listeners": [ |
50 | { | 38 | { |
@@ -65,13 +53,7 @@ | |||
65 | } | 53 | } |
66 | }, | 54 | }, |
67 | "bindings": { | 55 | "bindings": { |
68 | "value": { | 56 | "value": {"<-": "@owner.cancelLabel"} |
69 | "boundObject": { | ||
70 | "@": "owner" | ||
71 | }, | ||
72 | "boundObjectPropertyPath": "cancelLabel", | ||
73 | "oneway": true | ||
74 | } | ||
75 | }, | 57 | }, |
76 | "listeners": [ | 58 | "listeners": [ |
77 | { | 59 | { |
@@ -91,8 +73,8 @@ | |||
91 | } | 73 | } |
92 | } | 74 | } |
93 | } | 75 | } |
94 | } | 76 | |
95 | </script> | 77 | }</script> |
96 | 78 | ||
97 | 79 | ||
98 | </head> | 80 | </head> |
diff --git a/node_modules/montage/ui/popup/notifier.reel/notifier.js b/node_modules/montage/ui/popup/notifier.reel/notifier.js index 6346cd19..ac3dcff9 100755 --- a/node_modules/montage/ui/popup/notifier.reel/notifier.js +++ b/node_modules/montage/ui/popup/notifier.reel/notifier.js | |||
@@ -78,14 +78,12 @@ var Notifier = exports.Notifier = Montage.create(Component, /** @lends module:"m | |||
78 | popup = Popup.create(); | 78 | popup = Popup.create(); |
79 | this.popup = popup; | 79 | this.popup = popup; |
80 | popup.type = 'notify'; | 80 | popup.type = 'notify'; |
81 | popup.boxed = false; | ||
82 | this.application._notifyPopup = popup; | 81 | this.application._notifyPopup = popup; |
83 | 82 | ||
84 | notifier = Notifier.create(); | 83 | notifier = Notifier.create(); |
85 | popup.content = notifier; | 84 | popup.content = notifier; |
86 | } | 85 | } |
87 | notifier = popup.content; | 86 | notifier = popup.content; |
88 | //popup.modal = !!modal; | ||
89 | notifier.msg = msg; | 87 | notifier.msg = msg; |
90 | 88 | ||
91 | if (!position) { | 89 | if (!position) { |
@@ -100,7 +98,7 @@ var Notifier = exports.Notifier = Montage.create(Component, /** @lends module:"m | |||
100 | 98 | ||
101 | if(timeout) { | 99 | if(timeout) { |
102 | timeout = parseInt(timeout, 10) || 3000; | 100 | timeout = parseInt(timeout, 10) || 3000; |
103 | popup.autoDismiss = timeout; | 101 | popup.autoHide = timeout; |
104 | } | 102 | } |
105 | 103 | ||
106 | popup.show(); | 104 | popup.show(); |
diff --git a/node_modules/montage/ui/popup/popup.reel/popup.js b/node_modules/montage/ui/popup/popup.reel/popup.js index 2a61e75e..d0a7a1cc 100755 --- a/node_modules/montage/ui/popup/popup.reel/popup.js +++ b/node_modules/montage/ui/popup/popup.reel/popup.js | |||
@@ -21,8 +21,29 @@ var Popup = exports.Popup = Montage.create(Component, { /** @lends module:"modul | |||
21 | 21 | ||
22 | hasTemplate: {value: true}, | 22 | hasTemplate: {value: true}, |
23 | 23 | ||
24 | // anchor element to which this popup must be anchored to | 24 | // the HTML Element to which the popup must be anchored to |
25 | anchor: {value: null}, | 25 | anchorElement: {value: null}, |
26 | |||
27 | _anchor: {value: null}, | ||
28 | /** | ||
29 | * The HTMLElement or Montage Component that the popup must be anchored to | ||
30 | */ | ||
31 | anchor: { | ||
32 | get: function() { | ||
33 | return this._anchor; | ||
34 | }, | ||
35 | set: function(value) { | ||
36 | if(value) { | ||
37 | this._anchor = value; | ||
38 | if(value.nodeName) { | ||
39 | // HTMLElement | ||
40 | this.anchorElement = value; | ||
41 | } else { | ||