Class: ListCarte

ListCarte

Control to display a list of Cartes


new ListCarte(api, options)

Constructor

Parameters:
Name Type Description
api MacarteAPI
options Object
Properties
Name Type Argument Default Description
className string
size number <optional>
12

number of items in the list

target Element <optional>
selection boolean <optional>
false

enable list selection

check boolean <optional>
false

enable checkbox on lines

context string <optional>
'atlas'
sort string <optional>
''
search boolean <optional>
false

add search gilter

mode string <optional>
'list'

mode style list|gallery|mini

mini boolean <optional>
false

limit to mini mode content (for dialog)

permalink boolean <optional>
false
Source:
api/ListCarte.js
Fires:
  • select:user
  • event:check
  • event:select
  • event:search
  • event:click
  • event:dblclick
  • change:page
  • draw:item
  • draw:list

Methods


autocompleteAuthor(value)

Autocomplete author list

Parameters:
Name Type Description
value string
Source:
api/ListCarte.js

drawHead(li)

Show the map list

Parameters:
Name Type Description
li element

list element

Source:
api/ListCarte.js

drawItem(m, li)

Show the map list

Parameters:
Name Type Description
m Object

carte info

li element

list element

Source:
api/ListCarte.js

Set permalink (for search)

Source:
api/ListCarte.js

getStrAttributeValue(string}, value)

Get attribute value as string (translated)

Parameters:
Name Type Description
string}

filter

value *
Source:
api/ListCarte.js
Returns:
Type
string

removeFilter(filter)

Remove filter in the list

Parameters:
Name Type Description
filter string

filter name

Source:
api/ListCarte.js

setFilter(filter, value, icon)

Set search filter

Parameters:
Name Type Description
filter string

the filter name user|theme|type|premium...

value string
icon string

icon name (for themes)

Source:
api/ListCarte.js

showPage(page)

Show the current page

Parameters:
Name Type Description
page number
Source:
api/ListCarte.js

Update permalink (for search)

Source:
api/ListCarte.js