@cocreate/api 1.2.12 → 1.2.16
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.
- package/CHANGELOG.md +29 -0
- package/docs/form.html +199 -196
- package/docs/index.html +24 -18
- package/docs/module.html +29 -26
- package/docs/server.html +29 -26
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,32 @@
|
|
|
1
|
+
## [1.2.16](https://github.com/CoCreate-app/CoCreate-api/compare/v1.2.15...v1.2.16) (2021-11-27)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* update dependencies ([477f0a1](https://github.com/CoCreate-app/CoCreate-api/commit/477f0a1739c3348eef4eda3fa1e6427cce820960))
|
|
7
|
+
|
|
8
|
+
## [1.2.15](https://github.com/CoCreate-app/CoCreate-api/compare/v1.2.14...v1.2.15) (2021-11-27)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* update dependencies ([591faf3](https://github.com/CoCreate-app/CoCreate-api/commit/591faf379dfa4097c81a91b12404d9f69e89742e))
|
|
14
|
+
|
|
15
|
+
## [1.2.14](https://github.com/CoCreate-app/CoCreate-api/compare/v1.2.13...v1.2.14) (2021-11-27)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Bug Fixes
|
|
19
|
+
|
|
20
|
+
* update docs api and cocreateJS script ([38d04e2](https://github.com/CoCreate-app/CoCreate-api/commit/38d04e2437539b81f6953cb45b950c575a23dce3))
|
|
21
|
+
|
|
22
|
+
## [1.2.13](https://github.com/CoCreate-app/CoCreate-api/compare/v1.2.12...v1.2.13) (2021-11-26)
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
### Bug Fixes
|
|
26
|
+
|
|
27
|
+
* docs sidenav width ([3205573](https://github.com/CoCreate-app/CoCreate-api/commit/3205573efb1b76925b591b9de80b6c170634fa8c))
|
|
28
|
+
* updated action dependency to actions ([69b8950](https://github.com/CoCreate-app/CoCreate-api/commit/69b8950291d4b51b58fb04c5789f33de37119431))
|
|
29
|
+
|
|
1
30
|
## [1.2.12](https://github.com/CoCreate-app/CoCreate-api/compare/v1.2.11...v1.2.12) (2021-11-26)
|
|
2
31
|
|
|
3
32
|
|
package/docs/form.html
CHANGED
|
@@ -1,214 +1,217 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
|
|
4
|
-
<head>
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
</head>
|
|
19
|
-
|
|
20
|
-
<body>
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
4
|
+
<head>
|
|
5
|
+
<meta charset="utf-8">
|
|
6
|
+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
7
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
8
|
+
<title>CoCreate-api form Documentation | CoCreateJS </title>
|
|
9
|
+
<link rel="icon" type="image/png" sizes="32x32" href="https://cocreate.app/images/favicon.ico">
|
|
10
|
+
<meta name="description" content="An api helper component in vanilla javascript to setup thirdparty api intergrations. Apis can be accessible using HTML5 attributes and/or JavaScript API" />
|
|
11
|
+
<meta name="keywords" content="drag and drop, colaboration, dnd utility, drag and drop utility" />
|
|
12
|
+
<meta name="robots" content="index,follow" />
|
|
13
|
+
<meta property="og:image" content="https://cdn.cocreate.app/docs/api.png">
|
|
14
|
+
<!-- CoCreate CSS -->
|
|
15
|
+
<!-- CoCreate CSS -->
|
|
16
|
+
<link rel="stylesheet" href="https://cdn.cocreate.app/latest/CoCreate.min.css" type="text/css" />
|
|
17
|
+
<link rel="stylesheet" href="/docs/index.css" collection="files" document_id="60888216117c640e7596303f" name="src" type="text/css" save="true" />
|
|
18
|
+
</head>
|
|
19
|
+
|
|
20
|
+
<body>
|
|
21
|
+
<nav class="nav display:flex align-items:center left:0px background:whitesmoke padding-top:10px padding-bottom:10px" content_id="content" scroll="sticky-nav,hide-nav" scroll-up="10" scroll-down="10" collection="files" document_id="60395ef42b3ac232657040fd" name="src">
|
|
22
|
+
</nav>
|
|
23
|
+
<sidenav id="menuL" class="position:fixed top:0px left:0px overflow:hidden background:whitesmoke height:100vh width:0px width:300px@xl" resizable resize-target="[content_id='content']" resize-property="margin-left" resize-value="width">
|
|
24
|
+
<menu collection="files" document_id="603717b07de7fb350ae9fec8" name="src"></menu>
|
|
25
|
+
<div resize="right"></div>
|
|
26
|
+
</sidenav>
|
|
27
|
+
<main class="padding-top:15px padding:15px@lg@xl" content_id="content" id="CoCreate-api-form">
|
|
28
|
+
<div class="display:flex flex-wrap:wrap justify-content:space-between position:relative margin:10px">
|
|
29
|
+
<div class="display:flex align-items:center">
|
|
30
|
+
<h2>CoCreate-api form</h2>
|
|
31
|
+
</div>
|
|
32
|
+
<div class="display:flex align-items:center font-size:20px position:absolute right:0 padding:5px background:white">
|
|
33
|
+
<div class="display:flex align-items:center transition:0.3s padding-left:10px" share-network="true" share-text="An api helper component in vanilla javascript to setup thirdparty api intergrations. Apis can be accessible using HTML5 attributes and/or JavaScript API"
|
|
34
|
+
share-title="CoCreate API form" share-height="600" share-width="700" share-media="https://cdn.cocreate.app/docs/api.png" hover="display:block!important" hover-target=".social-networks">
|
|
35
|
+
<div class="display:none social-networks">
|
|
36
|
+
<a class="margin-right:15px" share-network='twitter' title="Share on twitter"><i class="fab fa-twitter"></i></a>
|
|
37
|
+
<a class="margin-right:15px" share-network='facebook' title="Share on Facebook"><i class="fab fa-facebook"></i></a>
|
|
38
|
+
<a class="margin-right:15px" share-network='instagram' title="Share on instagram"><i class="fab fa-instagram"></i></a>
|
|
39
|
+
</div>
|
|
40
|
+
<a class="margin-right:15px" share-network='share' title="Share on share"><i class="fas fa-share-alt"></i></a>
|
|
39
41
|
</div>
|
|
40
|
-
<a
|
|
42
|
+
<a href="https://github.com/CoCreate-app/CoCreate-dnd" target="_blank" class=""><i class="fab fa-github"></i></a>
|
|
41
43
|
</div>
|
|
42
|
-
<a href="https://github.com/CoCreate-app/CoCreate-dnd" target="_blank" class=""><i class="fab fa-github"></i></a>
|
|
43
44
|
</div>
|
|
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
|
-
new CoCreate.stripe(manager) //. register
|
|
104
|
-
}
|
|
105
|
-
</code></pre>
|
|
106
|
-
<h4>(4). Rebuild CoCreate-{moudle}.js by endpoint and action</h4>
|
|
107
|
-
<pre><code class="language-javascript">
|
|
108
|
-
var utils= require('../utils');
|
|
109
|
-
class CoCreateStripe {
|
|
110
|
-
constructor(wsManager) {
|
|
111
|
-
this.module_id="stripe";
|
|
112
|
-
....
|
|
45
|
+
<h1 class="max-width:500px margin:20px_10px line-height:1.5 font-size:16px font-weight:100">CoCreate-api is a simple api helper component in vanilla javascript used by JavaScript developers to create thirdparty api intergrations. Thirdparty apis can be accessible using HTML5 attributes and/or JavaScript API. CoCreate-api includes the
|
|
46
|
+
client component and server side for api processing.</p>
|
|
47
|
+
<div id="api-section" class="display:flex flex-wrap:wrap">
|
|
48
|
+
<div class="flex-grow:1 width:400px width:300px@xs padding:0px_10px margin-top:60px">
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
<div id="api-install" class="border-bottom:1px_solid_lightgrey" scroll scroll-intersect="color:dodgerblue" scroll-target="#api-install-section">
|
|
52
|
+
<span class="display:flex align-items:center width:fit-content" hover="display:block!important" hover-target='[href="#api-install"]'>
|
|
53
|
+
<h2 class="padding:5px_0px">Install</h2>
|
|
54
|
+
<a class="margin-left:10px display:none" href="#api-install"><i class="fas fa-link"></i></a>
|
|
55
|
+
</span>
|
|
56
|
+
</div>
|
|
57
|
+
|
|
58
|
+
<p class="padding:10px_0px line-height:1.5">
|
|
59
|
+
<pre><code class="language-bash">npm i @cocreate/api</code></pre>
|
|
60
|
+
</p>
|
|
61
|
+
<p class="padding:10px_0px line-height:1.5">Or you can use cdn link:</p>
|
|
62
|
+
<pre><code class="language-html"><script>https://cdn.cocreate.app/api/latest/CoCreate-api.min.js</script></code></pre>
|
|
63
|
+
|
|
64
|
+
<div>
|
|
65
|
+
<h2 id="api-server-run" hover="display:block" hover-target="" class="border-bottom:1px_solid_lightgrey padding:5px_0px">Server run</h2>
|
|
66
|
+
<a class="display:none" href="#api-server-run"><i class="fas fa-link"></i></a>
|
|
67
|
+
</div>
|
|
68
|
+
<pre><code class="language-javascript">npm run start</code></pre>
|
|
69
|
+
|
|
70
|
+
<div>
|
|
71
|
+
<h2 id="api-dependencies" hover="display:block" hover-target="" class="border-bottom:1px_solid_lightgrey margin-top:80px padding:5px_0px">Dependencies components</h2>
|
|
72
|
+
<a class="display:none" href="#api-dependencies"><i class="fas fa-link"></i></a>
|
|
73
|
+
</div>
|
|
74
|
+
<p class="padding:10px_0px line-height:1.5">
|
|
75
|
+
<strong>CoCreate.js</strong>,
|
|
76
|
+
<strong>CoCreate-api.js</strong>,
|
|
77
|
+
</p>
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
<div>
|
|
81
|
+
<h2 id="api-development" hover="display:block" hover-target="" class="border-bottom:1px_solid_lightgrey margin-top:80px padding:5px_0px">Development Guide</h2>
|
|
82
|
+
<a class="display:none" href="#api-development"><i class="fas fa-link"></i></a>
|
|
83
|
+
</div>
|
|
84
|
+
|
|
85
|
+
<h3 class="margin-top:20px padding:5px_0px">1. Directory structure</h3>
|
|
86
|
+
<pre><code class="language-javascript">
|
|
87
|
+
|- server
|
|
88
|
+
|- apis
|
|
89
|
+
|- {module_name} //. module directory
|
|
90
|
+
CoCreate-{module_name}.js
|
|
91
|
+
|- ...
|
|
92
|
+
crud.js
|
|
93
|
+
index.js
|
|
94
|
+
WSManger.js
|
|
95
|
+
</code></pre>
|
|
96
|
+
<h3 class="margin-top:20px padding:5px_0px">2. Development stage</h3>
|
|
97
|
+
<h4>(1). Add the module direcotry into server/apis</h4>
|
|
98
|
+
<h4>(2). Create CoCreate-{module}.js from CoCreate-xxx.js template</h4>
|
|
99
|
+
<h4>(3). Register the module in crud.js</h4>
|
|
100
|
+
<pre><code class="language-javascript">
|
|
101
|
+
const CoCreateStripe = require('./apis/stripe/Cocreate-stripe')
|
|
102
|
+
module.exports.WSManager = function(manager) {
|
|
103
|
+
new CoCreate.stripe(manager) //. register
|
|
113
104
|
}
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
105
|
+
</code></pre>
|
|
106
|
+
<h4>(4). Rebuild CoCreate-{moudle}.js by endpoint and action</h4>
|
|
107
|
+
<pre><code class="language-javascript">
|
|
108
|
+
var utils= require('../utils');
|
|
109
|
+
class CoCreateStripe {
|
|
110
|
+
constructor(wsManager) {
|
|
111
|
+
this.module_id="stripe";
|
|
112
|
+
....
|
|
118
113
|
}
|
|
114
|
+
init() {
|
|
115
|
+
if (this.wsManager) {
|
|
116
|
+
//. endpoint = module_name (ex: stripe)
|
|
117
|
+
this.wsManager.on(this.module_id, (socket, data) => this.sendStripe(socket, data));
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
async sendStripe(socket, data) {
|
|
121
|
+
let type = data['type'];
|
|
122
|
+
switch (type) {
|
|
123
|
+
case 'CreateCustomer': //. action name
|
|
124
|
+
... Get result by processing
|
|
125
|
+
utils.send_response(this.wsManager, socket, {"type":type,"response":result}, this.module_id)
|
|
126
|
+
break;
|
|
127
|
+
....
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
}//end Class
|
|
131
|
+
module.exports = CoCreateStripe;
|
|
132
|
+
</code></pre>
|
|
133
|
+
|
|
134
|
+
<h3 class="margin-top:20px padding:5px_0px">3. Notes</h3>
|
|
135
|
+
<h4>(1). Response should be object that have <code class="language-js">type</code> and <code class="language-js">response</code> </h4>
|
|
136
|
+
<div class="padding-left:1rem">
|
|
137
|
+
<p><code class="language-js">type</code>: action name</p>
|
|
138
|
+
<p><code class="language-js">response</code>: result</p>
|
|
139
|
+
<pre><code class="language-javascript">{
|
|
140
|
+
type: action_name, //. string
|
|
141
|
+
response: result //. object or array
|
|
119
142
|
}
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
}//end Class
|
|
131
|
-
module.exports = CoCreateStripe;
|
|
132
|
-
</code></pre>
|
|
133
|
-
|
|
134
|
-
<h3 class="margin-top:20px padding:5px_0px">3. Notes</h3>
|
|
135
|
-
<h4>(1). Response should be object that have <code class="language-js">type</code> and <code class="language-js">response</code> </h4>
|
|
136
|
-
<div class="padding-left:1rem">
|
|
137
|
-
<p><code class="language-js">type</code>: action name</p>
|
|
138
|
-
<p><code class="language-js">response</code>: result</p>
|
|
143
|
+
</code></pre>
|
|
144
|
+
</div>
|
|
145
|
+
<h4>(2). Endpoint and moudle_id is same</h4>
|
|
146
|
+
<h4>(3). Send response</h4>
|
|
147
|
+
<pre><code class="language-javascript">
|
|
148
|
+
utils.send_response(that.wsManager, socket, {"type":action_name,"response":result}, moudle_id)
|
|
149
|
+
</code></pre>
|
|
150
|
+
<h4>(4). Request data structure </h4>
|
|
139
151
|
<pre><code class="language-javascript">{
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
</code></pre>
|
|
156
|
-
|
|
157
|
-
<h2 class="border-bottom:1px_solid_lightgrey margin-top:20px padding:5px_0px">How Does It Works</h2>
|
|
158
|
-
<p>CoCreate-api server module works based on cocreate.api. </p>
|
|
159
|
-
|
|
160
|
-
<p>xxxxxx <code class="language-js">action_{action_name}</code>. <code class="language-js">pre_{action_name}</code></p>
|
|
161
|
-
|
|
162
|
-
<h2 class="border-bottom:1px_solid_lightgrey margin-top:20px padding:5px_0px">Effects and Styles</h2>
|
|
163
|
-
|
|
164
|
-
<h2 class="border-bottom:1px_solid_lightgrey margin-top:20px padding:5px_0px">Events</h2>
|
|
165
|
-
<h4><span></span><span class="cocreate-badge success"></span></h4>
|
|
166
|
-
|
|
167
|
-
</div>
|
|
168
|
-
|
|
169
|
-
<div class="flex-grow:1 width:300px padding:0px_10px margin-top:60px border-bottom:1px_solid_lightgrey">
|
|
170
|
-
|
|
171
|
-
<!-- SandBox -->
|
|
172
|
-
<div id="api-demo" class="border-bottom:1px_solid_lightgrey" scroll scroll-intersect="color:dodgerblue" scroll-target="#api-demo-section">
|
|
173
|
-
<span class="display:flex align-items:center width:fit-content" hover="display:block!important" hover-target='[href="#api-demo"]'>
|
|
174
|
-
<h2 class="padding:5px_0px">Demo</h2>
|
|
175
|
-
<a class="margin-left:10px display:none" href="#api-demo"><i class="fas fa-link"></i></a>
|
|
176
|
-
</span>
|
|
152
|
+
type: action_name, //. string
|
|
153
|
+
data: request_data //. object or array
|
|
154
|
+
}
|
|
155
|
+
</code></pre>
|
|
156
|
+
|
|
157
|
+
<h2 class="border-bottom:1px_solid_lightgrey margin-top:20px padding:5px_0px">How Does It Works</h2>
|
|
158
|
+
<p>CoCreate-api server module works based on cocreate.api. </p>
|
|
159
|
+
|
|
160
|
+
<p>xxxxxx <code class="language-js">action_{action_name}</code>. <code class="language-js">pre_{action_name}</code></p>
|
|
161
|
+
|
|
162
|
+
<h2 class="border-bottom:1px_solid_lightgrey margin-top:20px padding:5px_0px">Effects and Styles</h2>
|
|
163
|
+
|
|
164
|
+
<h2 class="border-bottom:1px_solid_lightgrey margin-top:20px padding:5px_0px">Events</h2>
|
|
165
|
+
<h4><span></span><span class="cocreate-badge success"></span></h4>
|
|
166
|
+
|
|
177
167
|
</div>
|
|
178
|
-
|
|
179
|
-
<div class="
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
168
|
+
|
|
169
|
+
<div class="flex-grow:1 width:300px padding:0px_10px margin-top:60px border-bottom:1px_solid_lightgrey">
|
|
170
|
+
|
|
171
|
+
<!-- SandBox -->
|
|
172
|
+
<div id="api-demo" class="border-bottom:1px_solid_lightgrey" scroll scroll-intersect="color:dodgerblue" scroll-target="#api-demo-section">
|
|
173
|
+
<span class="display:flex align-items:center width:fit-content" hover="display:block!important" hover-target='[href="#api-demo"]'>
|
|
174
|
+
<h2 class="padding:5px_0px">Demo</h2>
|
|
175
|
+
<a class="margin-left:10px display:none" href="#api-demo"><i class="fas fa-link"></i></a>
|
|
176
|
+
</span>
|
|
177
|
+
</div>
|
|
178
|
+
|
|
179
|
+
<div class="position:sticky top:0 padding:15px_0px height:100vh">
|
|
180
|
+
<!-- SandBox -->
|
|
181
|
+
<div class="container svColumn overflow:hidden card position:relative border-radius:2px width:auto height:100%" id="sandbox">
|
|
182
|
+
<div class="font-size:20px position:absolute top:10px right:10px opacity:0.6">
|
|
183
|
+
<a class="margin-right:10px" id="code" show="#preview" hide="#code, #view"><i class="far fa-eye"></i></a>
|
|
184
|
+
<a class="margin-right:10px hidden" id="preview" show="#code, #view" hide="#preview"><i class="fas fa-code"></i></a>
|
|
185
|
+
<a class="margin-right:5px" fullscreen target="#playground"><i class="fas fa-expand"></i></a>
|
|
186
|
+
</div>
|
|
187
|
+
<div class="svRow">
|
|
188
|
+
|
|
189
|
+
<div class="svColumn">
|
|
190
|
+
|
|
191
|
+
<div class="svPanel" id="view">
|
|
192
|
+
<textarea collection="demos" document_id="" name="demo" save="false" id="demo" class="height:100% width:100% border:none resize:none padding:5px"></textarea>
|
|
193
|
+
</div>
|
|
194
|
+
<div class="svSplitter svHorizontal"> </div>
|
|
195
|
+
|
|
196
|
+
<div class="svPanel">
|
|
197
|
+
<iframe get-value="demo" frameBorder="0" height="100%" width="100%" class="min-width:300px"></iframe>
|
|
198
|
+
</div>
|
|
199
|
+
|
|
200
|
+
</div>
|
|
190
201
|
</div>
|
|
191
|
-
<div class="svSplitter svHorizontal"> </div>
|
|
192
|
-
<div class="svPanel"> <iframe get-value="7" frameBorder="0" height="100%" width="100%" class="min-width:300px"></iframe> </div>
|
|
193
202
|
</div>
|
|
194
|
-
|
|
203
|
+
<!-- End SandBox -->
|
|
195
204
|
</div>
|
|
196
|
-
<!-- End SandBox -->
|
|
197
205
|
</div>
|
|
198
206
|
</div>
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
}
|
|
209
|
-
</script>
|
|
210
|
-
<!--CoCreateJS CDN-->
|
|
211
|
-
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
212
|
-
</body>
|
|
207
|
+
<button href="https://github.com/CoCreate-app/CoCreate-api/tree/master/docs/index.html?message=docs%3A%20describe%20your%20change..." target="_blank" class="position:fixed bottom:15px right:15px padding:15px background:dodgerblue grow-hover border-radius:50%">
|
|
208
|
+
<i class="fas fa-pencil-alt"></i>
|
|
209
|
+
</button>
|
|
210
|
+
</main>
|
|
211
|
+
|
|
212
|
+
<script src="./apikey.js"></script>
|
|
213
|
+
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
214
|
+
|
|
215
|
+
</body>
|
|
213
216
|
|
|
214
217
|
</html>
|
package/docs/index.html
CHANGED
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
<nav class="nav display:flex align-items:center left:0px background:whitesmoke padding-top:10px padding-bottom:10px" content_id="content" scroll="sticky-nav,hide-nav" scroll-up="10" scroll-down="10" collection="files" document_id="60395ef42b3ac232657040fd"
|
|
23
23
|
name="src">
|
|
24
24
|
</nav>
|
|
25
|
-
<sidenav id="menuL" class="position:fixed top:0px left:0px background:whitesmoke height:100vh width:
|
|
25
|
+
<sidenav id="menuL" class="position:fixed top:0px left:0px overflow:hidden background:whitesmoke height:100vh width:0px width:300px@xl" resizable resize-target="[content_id='content']" resize-property="margin-left" resize-value="width">
|
|
26
26
|
<menu collection="files" document_id="603717b07de7fb350ae9fec8" name="src"></menu>
|
|
27
27
|
<div resize="right"></div>
|
|
28
28
|
</sidenav>
|
|
@@ -44,11 +44,8 @@
|
|
|
44
44
|
<a href="https://github.com/CoCreate-app/CoCreate-dnd" target="_blank" class=""><i class="fab fa-github"></i></a>
|
|
45
45
|
</div>
|
|
46
46
|
</div>
|
|
47
|
-
<a href="https://github.com/CoCreate-app/CoCreate-dnd" target="_blank" class=""><i class="fab fa-github"></i></a>
|
|
48
|
-
</div>
|
|
49
|
-
</div>
|
|
50
47
|
<h1 class="max-width:500px margin:20px_10px line-height:1.5 font-size:16px font-weight:100">CoCreate-api is a simple api helper component in vanilla javascript used by JavaScript developers to create thirdparty api intergrations. Thirdparty apis can be accessible using HTML5 attributes and/or JavaScript API. CoCreate-api includes the
|
|
51
|
-
client component and server side for api processing.</
|
|
48
|
+
client component and server side for api processing.</h1>
|
|
52
49
|
<div id="api-section" class="display:flex flex-wrap:wrap">
|
|
53
50
|
<div class="flex-grow:1 width:400px width:300px@xs padding:0px_10px margin-top:60px">
|
|
54
51
|
|
|
@@ -201,23 +198,31 @@
|
|
|
201
198
|
<!-- SandBox -->
|
|
202
199
|
<div id="api-demo" class="border-bottom:1px_solid_lightgrey" scroll scroll-intersect="color:dodgerblue" scroll-target="#api-demo-section">
|
|
203
200
|
<span class="display:flex align-items:center width:fit-content" hover="display:block!important" hover-target='[href="#api-demo"]'>
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
201
|
+
<h2 class="padding:5px_0px">Demo</h2>
|
|
202
|
+
<a class="margin-left:10px display:none" href="#api-demo"><i class="fas fa-link"></i></a>
|
|
203
|
+
</span>
|
|
207
204
|
</div>
|
|
208
205
|
<div class="position:sticky top:0 padding:15px_0px height:100vh">
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
206
|
+
<!-- SandBox -->
|
|
207
|
+
<div class="container svColumn overflow:hidden card position:relative border-radius:2px width:auto height:100%" id="sandbox">
|
|
208
|
+
<div class="font-size:20px position:absolute top:10px right:10px opacity:0.6">
|
|
209
|
+
<a class="margin-right:10px" id="code" show="#preview" hide="#code, #view"><i class="far fa-eye"></i></a>
|
|
210
|
+
<a class="margin-right:10px hidden" id="preview" show="#code, #view" hide="#preview"><i class="fas fa-code"></i></a>
|
|
211
|
+
<a class="margin-right:5px" fullscreen target="#playground"><i class="fas fa-expand"></i></a>
|
|
212
|
+
</div>
|
|
214
213
|
<div class="svRow">
|
|
214
|
+
|
|
215
215
|
<div class="svColumn">
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
|
|
217
|
+
<div class="svPanel" id="view">
|
|
218
|
+
<textarea collection="demos" document_id="" name="demo" save="false" id="demo" class="height:100% width:100% border:none resize:none padding:5px"></textarea>
|
|
218
219
|
</div>
|
|
219
220
|
<div class="svSplitter svHorizontal"> </div>
|
|
220
|
-
|
|
221
|
+
|
|
222
|
+
<div class="svPanel">
|
|
223
|
+
<iframe get-value="demo" frameBorder="0" height="100%" width="100%" class="min-width:300px"></iframe>
|
|
224
|
+
</div>
|
|
225
|
+
|
|
221
226
|
</div>
|
|
222
227
|
</div>
|
|
223
228
|
</div>
|
|
@@ -225,9 +230,10 @@
|
|
|
225
230
|
</div>
|
|
226
231
|
</div>
|
|
227
232
|
</div>
|
|
233
|
+
|
|
228
234
|
<button href="https://github.com/CoCreate-app/CoCreate-api/tree/master/docs/index.html?message=docs%3A%20describe%20your%20change..." target="_blank" class="position:fixed bottom:15px right:15px padding:15px background:dodgerblue grow-hover border-radius:50%">
|
|
229
|
-
|
|
230
|
-
|
|
235
|
+
<i class="fas fa-pencil-alt"></i>
|
|
236
|
+
</button>
|
|
231
237
|
</main>
|
|
232
238
|
<script src="/apikey.js"></script>
|
|
233
239
|
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
package/docs/module.html
CHANGED
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
<body>
|
|
21
21
|
<nav class="nav display:flex align-items:center left:0px background:whitesmoke padding-top:10px padding-bottom:10px" content_id="content" scroll="sticky-nav,hide-nav" scroll-up="10" scroll-down="10" collection="files" document_id="60395ef42b3ac232657040fd" name="src">
|
|
22
22
|
</nav>
|
|
23
|
-
<sidenav id="menuL" class="position:fixed top:0px left:0px background:whitesmoke height:100vh width:
|
|
23
|
+
<sidenav id="menuL" class="position:fixed top:0px left:0px overflow:hidden background:whitesmoke height:100vh width:0px width:300px@xl" resizable resize-target="[content_id='content']" resize-property="margin-left" resize-value="width">
|
|
24
24
|
<menu collection="files" document_id="603717b07de7fb350ae9fec8" name="src"></menu>
|
|
25
25
|
<div resize="right"></div>
|
|
26
26
|
</sidenav>
|
|
@@ -167,38 +167,41 @@
|
|
|
167
167
|
|
|
168
168
|
|
|
169
169
|
<div class="position:sticky top:0 padding:15px_0px height:100vh">
|
|
170
|
-
|
|
171
|
-
<div class="
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
<i class="fas fa-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
<div class="
|
|
178
|
-
|
|
179
|
-
|
|
170
|
+
<!-- SandBox -->
|
|
171
|
+
<div class="container svColumn overflow:hidden card position:relative border-radius:2px width:auto height:100%" id="sandbox">
|
|
172
|
+
<div class="font-size:20px position:absolute top:10px right:10px opacity:0.6">
|
|
173
|
+
<a class="margin-right:10px" id="code" show="#preview" hide="#code, #view"><i class="far fa-eye"></i></a>
|
|
174
|
+
<a class="margin-right:10px hidden" id="preview" show="#code, #view" hide="#preview"><i class="fas fa-code"></i></a>
|
|
175
|
+
<a class="margin-right:5px" fullscreen target="#playground"><i class="fas fa-expand"></i></a>
|
|
176
|
+
</div>
|
|
177
|
+
<div class="svRow">
|
|
178
|
+
|
|
179
|
+
<div class="svColumn">
|
|
180
|
+
|
|
181
|
+
<div class="svPanel" id="view">
|
|
182
|
+
<textarea collection="demos" document_id="" name="demo" save="false" id="demo" class="height:100% width:100% border:none resize:none padding:5px"></textarea>
|
|
183
|
+
</div>
|
|
184
|
+
<div class="svSplitter svHorizontal"> </div>
|
|
185
|
+
|
|
186
|
+
<div class="svPanel">
|
|
187
|
+
<iframe get-value="demo" frameBorder="0" height="100%" width="100%" class="min-width:300px"></iframe>
|
|
188
|
+
</div>
|
|
189
|
+
|
|
180
190
|
</div>
|
|
181
|
-
<div class="svSplitter svHorizontal"> </div>
|
|
182
|
-
<div class="svPanel"> <iframe get-value="7" frameBorder="0" height="100%" width="100%" class="min-width:300px"></iframe> </div>
|
|
183
191
|
</div>
|
|
184
192
|
</div>
|
|
185
|
-
|
|
186
|
-
<!-- End SandBox -->
|
|
193
|
+
<!-- End SandBox -->
|
|
187
194
|
</div>
|
|
188
195
|
</div>
|
|
189
196
|
</div>
|
|
190
197
|
<button href="https://github.com/CoCreate-app/CoCreate-api/tree/master/docs/index.html?message=docs%3A%20describe%20your%20change..." target="_blank" class="position:fixed bottom:15px right:15px padding:15px background:dodgerblue grow-hover border-radius:50%">
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
}
|
|
199
|
-
</script>
|
|
200
|
-
<!--CoCreateJS CDN-->
|
|
201
|
-
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
198
|
+
<i class="fas fa-pencil-alt"></i>
|
|
199
|
+
</button>
|
|
200
|
+
</main>
|
|
201
|
+
|
|
202
|
+
<script src="./apikey.js"></script>
|
|
203
|
+
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
204
|
+
|
|
202
205
|
</body>
|
|
203
206
|
|
|
204
207
|
</html>
|
package/docs/server.html
CHANGED
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
<body>
|
|
21
21
|
<nav class="nav display:flex align-items:center left:0px background:whitesmoke padding-top:10px padding-bottom:10px" content_id="content" scroll="sticky-nav,hide-nav" scroll-up="10" scroll-down="10" collection="files" document_id="60395ef42b3ac232657040fd" name="src">
|
|
22
22
|
</nav>
|
|
23
|
-
<sidenav id="menuL" class="position:fixed top:0px left:0px background:whitesmoke height:100vh width:
|
|
23
|
+
<sidenav id="menuL" class="position:fixed top:0px left:0px overflow:hidden background:whitesmoke height:100vh width:0px width:300px@xl" resizable resize-target="[content_id='content']" resize-property="margin-left" resize-value="width">
|
|
24
24
|
<menu collection="files" document_id="603717b07de7fb350ae9fec8" name="src"></menu>
|
|
25
25
|
<div resize="right"></div>
|
|
26
26
|
</sidenav>
|
|
@@ -178,38 +178,41 @@
|
|
|
178
178
|
</div>
|
|
179
179
|
|
|
180
180
|
<div class="position:sticky top:0 padding:15px_0px height:100vh">
|
|
181
|
-
|
|
182
|
-
<div class="
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
<i class="fas fa-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
<div class="
|
|
189
|
-
|
|
190
|
-
|
|
181
|
+
<!-- SandBox -->
|
|
182
|
+
<div class="container svColumn overflow:hidden card position:relative border-radius:2px width:auto height:100%" id="sandbox">
|
|
183
|
+
<div class="font-size:20px position:absolute top:10px right:10px opacity:0.6">
|
|
184
|
+
<a class="margin-right:10px" id="code" show="#preview" hide="#code, #view"><i class="far fa-eye"></i></a>
|
|
185
|
+
<a class="margin-right:10px hidden" id="preview" show="#code, #view" hide="#preview"><i class="fas fa-code"></i></a>
|
|
186
|
+
<a class="margin-right:5px" fullscreen target="#playground"><i class="fas fa-expand"></i></a>
|
|
187
|
+
</div>
|
|
188
|
+
<div class="svRow">
|
|
189
|
+
|
|
190
|
+
<div class="svColumn">
|
|
191
|
+
|
|
192
|
+
<div class="svPanel" id="view">
|
|
193
|
+
<textarea collection="demos" document_id="" name="demo" save="false" id="demo" class="height:100% width:100% border:none resize:none padding:5px"></textarea>
|
|
194
|
+
</div>
|
|
195
|
+
<div class="svSplitter svHorizontal"> </div>
|
|
196
|
+
|
|
197
|
+
<div class="svPanel">
|
|
198
|
+
<iframe get-value="demo" frameBorder="0" height="100%" width="100%" class="min-width:300px"></iframe>
|
|
199
|
+
</div>
|
|
200
|
+
|
|
191
201
|
</div>
|
|
192
|
-
<div class="svSplitter svHorizontal"> </div>
|
|
193
|
-
<div class="svPanel"> <iframe get-value="7" frameBorder="0" height="100%" width="100%" class="min-width:300px"></iframe> </div>
|
|
194
202
|
</div>
|
|
195
203
|
</div>
|
|
196
|
-
|
|
197
|
-
<!-- End SandBox -->
|
|
204
|
+
<!-- End SandBox -->
|
|
198
205
|
</div>
|
|
199
206
|
</div>
|
|
200
207
|
</div>
|
|
201
208
|
<button href="https://github.com/CoCreate-app/CoCreate-api/tree/master/docs/index.html?message=docs%3A%20describe%20your%20change..." target="_blank" class="position:fixed bottom:15px right:15px padding:15px background:dodgerblue grow-hover border-radius:50%">
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
}
|
|
210
|
-
</script>
|
|
211
|
-
<!--CoCreateJS CDN-->
|
|
212
|
-
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
209
|
+
<i class="fas fa-pencil-alt"></i>
|
|
210
|
+
</button>
|
|
211
|
+
</main>
|
|
212
|
+
|
|
213
|
+
<script src="./apikey.js"></script>
|
|
214
|
+
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
215
|
+
|
|
213
216
|
</body>
|
|
214
217
|
|
|
215
218
|
</html>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cocreate/api",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.16",
|
|
4
4
|
"description": "A simple api helper component in vanilla javascript used by JavaScript developers to create thirdparty api intergrations. CoCreate-api includes the client component and server side for api processing. Thirdparty apis can be accessible using HTML5 attributes and/or JavaScript API. ",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"thirdparty-api-intergration",
|
|
@@ -62,11 +62,11 @@
|
|
|
62
62
|
"webpack-log": "^3.0.1"
|
|
63
63
|
},
|
|
64
64
|
"dependencies": {
|
|
65
|
-
"@cocreate/
|
|
66
|
-
"@cocreate/crud-client": "^1.4.
|
|
67
|
-
"@cocreate/docs": "^1.2.
|
|
68
|
-
"@cocreate/hosting": "^1.2.
|
|
69
|
-
"@cocreate/render": "^1.3.
|
|
70
|
-
"@cocreate/socket-client": "^1.4.
|
|
65
|
+
"@cocreate/actions": "^1.3.23",
|
|
66
|
+
"@cocreate/crud-client": "^1.4.38",
|
|
67
|
+
"@cocreate/docs": "^1.2.60",
|
|
68
|
+
"@cocreate/hosting": "^1.2.56",
|
|
69
|
+
"@cocreate/render": "^1.3.21",
|
|
70
|
+
"@cocreate/socket-client": "^1.4.14"
|
|
71
71
|
}
|
|
72
72
|
}
|