Skip to content

Commit f0bd2d6

Browse files
committed
Add demo, improve readme. Fix download btn.
1 parent de5a932 commit f0bd2d6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+9259
-248
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
.meteor/local
22
.meteor/meteorite
3+
packages

.versions

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ ddp@1.1.0
1414
deps@1.0.7
1515
edgee:slingshot@0.6.2
1616
ejson@1.0.6
17-
elevatedevdesign:autoform-slingshot@0.0.1-rc.1
17+
elevatedevdesign:autoform-slingshot@0.0.1
1818
geojson-utils@1.0.3
1919
html-tools@1.0.4
2020
htmljs@1.0.4
@@ -23,7 +23,7 @@ jquery@1.11.3_2
2323
json@1.0.3
2424
less@1.0.14
2525
livedata@1.0.13
26-
local-test:elevatedevdesign:autoform-slingshot@0.0.1-rc.1
26+
local-test:elevatedevdesign:autoform-slingshot@0.0.1
2727
logging@1.0.7
2828
meteor@1.1.6
2929
minifiers@1.1.5

README.md

Lines changed: 33 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -5,40 +5,41 @@ elevatedevdesign:autoform-slingshot
55

66
## Config
77

8-
type: String,
9-
autoform: {
10-
type: "slingshot",
11-
multi: true, // defaults to true, meta setting, changes defaults
12-
ui: {
13-
hideList: true,
14-
hideIcons: true,
15-
noPreview: true,
16-
hideDownload: true,
17-
multipleUpload // only applies to file chooser
18-
}
19-
slingshot: {
20-
downloadUrl( data ) // for download btn and preview, should return err, resp { src: 'downloadUrl'}
21-
replaceOnChange
22-
directives: [
23-
{
24-
name: "Files",
25-
onBeforeUpload: function(){}
8+
type: afSlingshot.fileSchema,
9+
autoform: {
10+
type: "slingshot",
11+
multi: true, // defaults to true, meta setting, changes defaults
12+
ui: {
13+
hideList: true,
14+
hideIcons: true,
15+
noPreview: true,
16+
hideDownload: true,
17+
multipleUpload // only applies to file chooser
2618
}
27-
]
28-
}
29-
}
19+
slingshot: {
20+
downloadUrl( data ) // for download btn and preview, should return err, resp { src: 'downloadUrl'}
21+
replaceOnChange
22+
directives: [
23+
{
24+
name: "Files",
25+
onBeforeUpload: function(){}
26+
}
27+
]
28+
}
29+
}
30+
31+
Type can also be
3032

31-
// NOTICE! These are required for type: [Object].
32-
'file.key': { type: String },
33-
'file.filename': { type: String },
34-
'file.src': { type: String },
35-
'file.directive': { type: String },
36-
'file.type': { type: String }
33+
* `String`
34+
* `[afSlingshot.fileSchema]`
3735

38-
## Icons
39-
Icons are set via CSS.
4036

4137
## TODO
42-
Show errors
43-
Add tests
44-
Invert data structure. Currently uploader -> file info, make it file -> attached uploader
38+
* The big one - Show errors
39+
* Correctly stop uploads that are removed
40+
* Add Remove button for multi = false type
41+
* i18n support
42+
* Support for more than just bootstrap and plain
43+
* Better icon support for non-images
44+
* Detect when a previously saved file is an image (currently only on recent uploads)
45+
* Add more tests

demo/.gitignore

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
.DS_Store
2+
*.sublime-project
3+
*.sublime-workspace
4+
dump
5+
settings.json
6+
settings.prod.json
7+
packages/test-proxy
8+
packages

demo/.meteor/.finished-upgraders

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# This file contains information which helps Meteor properly upgrade your
2+
# app when you run 'meteor update'. You should check it into version control
3+
# with your project.
4+
5+
notices-for-0.9.0
6+
notices-for-0.9.1
7+
0.9.4-platform-file
8+
notices-for-facebook-graph-api-2

demo/.meteor/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
local

demo/.meteor/.id

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# This file contains a token that is unique to your project.
2+
# Check it into your repository along with the rest of this directory.
3+
# It can be used for purposes such as:
4+
# - ensuring you don't accidentally deploy one app on top of another
5+
# - providing package authors with aggregated statistics
6+
7+
1kwv2roc5la1o1xhdjcj

demo/.meteor/cordova-plugins

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+

demo/.meteor/platforms

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
server
2+
browser

demo/.meteor/release

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
METEOR@1.1.0.3

0 commit comments

Comments
 (0)