-
Notifications
You must be signed in to change notification settings - Fork 0
/
NavigatorID.cljs
150 lines (101 loc) · 3.81 KB
/
NavigatorID.cljs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
(ns web.dom.NavigatorID
"The NavigatorID interface contains methods and properties related
the identity of the browser."
(:refer-clojure :exclude []))
(defn taint-enabled
"Method.
The NavigatorID.taintEnabled() method always returns false.
`result = window.navigator.taintEnabled()`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/taintEnabled`"
[this ]
(-> this (.taintEnabled)))
(defn app-code-name
"Property.
The value of the NavigatorID.appCodeName property is always \\\"Mozilla\\\",
any browser. This property is kept only for compatibility purposes.
`codeName = window.navigator.appCodeName`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/appCodeName`"
[this]
(-> this (.-appCodeName)))
(defn set-app-code-name!
"Property.
The value of the NavigatorID.appCodeName property is always \\\"Mozilla\\\",
any browser. This property is kept only for compatibility purposes.
`codeName = window.navigator.appCodeName`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/appCodeName`"
[this val]
(aset this "appCodeName" val))
(defn app-name
"Property.
The value of the NavigatorID.appName property is always \\\"Netscape\\\",
any browser.
`appName = window.navigator.appName`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/appName`"
[this]
(-> this (.-appName)))
(defn set-app-name!
"Property.
The value of the NavigatorID.appName property is always \\\"Netscape\\\",
any browser.
`appName = window.navigator.appName`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/appName`"
[this val]
(aset this "appName" val))
(defn app-version
"Property.
Returns either \\\"4.0\\\" or a string representing version information
the browser.
`window.navigator.appVersion`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/appVersion`"
[this]
(-> this (.-appVersion)))
(defn set-app-version!
"Property.
Returns either \\\"4.0\\\" or a string representing version information
the browser.
`window.navigator.appVersion`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/appVersion`"
[this val]
(aset this "appVersion" val))
(defn platform
"Property.
Returns a string representing the platform of the browser. The
allows browsers to always return the empty string, so don't rely
this property to get a reliable answer.
`platform = navigator.platform`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/platform`"
[this]
(-> this (.-platform)))
(defn set-platform!
"Property.
Returns a string representing the platform of the browser. The
allows browsers to always return the empty string, so don't rely
this property to get a reliable answer.
`platform = navigator.platform`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/platform`"
[this val]
(aset this "platform" val))
(defn product
"Property.
The value of the NavigatorID.product property is always \\\"Gecko\\\",
any browser.
`productName = window.navigator.product`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/product`"
[this]
(-> this (.-product)))
(defn set-product!
"Property.
The value of the NavigatorID.product property is always \\\"Gecko\\\",
any browser.
`productName = window.navigator.product`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/product`"
[this val]
(aset this "product" val))
(defn user-agent
"Property.
The NavigatorID.userAgent read-only property returns the user
string for the current browser.
`var ua = window.navigator.userAgent;`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/userAgent`"
[this]
(-> this (.-userAgent)))