mmo-gallery
1 symbole · générée le 30 Nov 2026
mmo-gallery
mmo-gallery.jhs:1Images in order, each with its description (what a visitor who cannot see it reads): an article's photos, a project's. Its value is a list of {src, alt, file} -- src the image's address (its public one, relative to the site, when it went to a public label: edms/public/12/a.jpg), file its id in mmo.edms. Images are sent to mmo.edms (several at once), or chosen among those sent already; moved by dragging them, or with their arrows.
- Étend
CustomShadowElement
Index
| value | the images: a list, or its json | |
| url | where mmo.edms' api is: the page's (MMO.edms.config.url) by default | |
| token | the session's CSRF token: the page's by default | |
| labels | the labels of the images sent, and those the library shows: ids, or quoted paths and "#tags" | |
| max | the most images it holds: none by default | |
| readonly | the images to see, not to change | |
| min-width | the width, in pixels, a photo needs where it goes (1600): a narrower one says so -- it would be enlarged, and blurred (MMO.edms.imageSize) | |
| value accessor | ||
| max accessor | an attribute observed is set as a property: each has its setter | |
| readonly accessor | ||
| minWidth accessor | an attribute observed is set as a property | |
| init() | ||
| api() | ||
| changed() | The value changed: drawn again, and told | |
| addFiles(files) | Add images of mmo.edms, after those there, as many as max lets | |
| pickFromLibrary() | Choose images already sent, among those of labels | |
| filesChange(input) | Send the images chosen in the file input | |
| send(files) async | Send $files to mmo.edms, one after the other, then add them | |
| move(from, to) | Move the image $from to $to | |
| remove(index) | ||
| draw() | Draw the images | |
| .uploading | set while images are sent |
Attributs7
value
mmo-gallery.jhsthe images: a list, or its json
value
url
mmo-gallery.jhswhere mmo.edms' api is: the page's (MMO.edms.config.url) by default
url
token
mmo-gallery.jhsthe session's CSRF token: the page's by default
token
labels
mmo-gallery.jhsthe labels of the images sent, and those the library shows: ids, or quoted paths and "#tags"
labels
max
mmo-gallery.jhsthe most images it holds: none by default
max
readonly
mmo-gallery.jhsthe images to see, not to change
readonly
min-width
mmo-gallery.jhsthe width, in pixels, a photo needs where it goes (1600): a narrower one says so -- it would be enlarged, and blurred (MMO.edms.imageSize)
min-width
Propriétés4
value
accessormmo-gallery.jhs:39- Type
Array<{src: string, alt: string, file: ?*
max
accessormmo-gallery.jhs:65an attribute observed is set as a property: each has its setter
- Type
number
readonly
accessormmo-gallery.jhs:78- Type
boolean
minWidth
accessormmo-gallery.jhs:88an attribute observed is set as a property
Méthodes10
init()
mmo-gallery.jhs:29api()
mmo-gallery.jhs:99| retourne | MMO.edms.Api | the api of url and token, the page's by default |
changed()
mmo-gallery.jhs:106The value changed: drawn again, and told
addFiles(files)
mmo-gallery.jhs:115Add images of mmo.edms, after those there, as many as max lets
| files | Array<Object> | - as the api gives them |
pickFromLibrary()
mmo-gallery.jhs:128Choose images already sent, among those of labels
| retourne | Promise |
filesChange(input)
mmo-gallery.jhs:137Send the images chosen in the file input
| input | HTMLInputElement |
send(files)
asyncmmo-gallery.jhs:148Send $files to mmo.edms, one after the other, then add them
| files | Array<File> | |
| retourne | Promise |
move(from, to)
mmo-gallery.jhs:170Move the image $from to $to
| from | number | |
| to | number |
remove(index)
mmo-gallery.jhs:180| index | number |
draw()
mmo-gallery.jhs:188Draw the images
Points d'accroche CSS1
.uploading
mmo-gallery.jhsset while images are sent
.uploading