Commit Graph

86 Commits

Author SHA1 Message Date
Rijk van Zanten
631d152c79 Various (#543)
* Fix default size of cards

* Fix layout picker not auto closing

* Fix cards getting huge when theres less than 1 row
2020-05-08 18:27:59 -04:00
Rijk van Zanten
e3120afc7d Fix cp duplication and default values (#542)
* Fix cp duplication and default values

* Fix tests
2020-05-08 17:43:46 -04:00
Rijk van Zanten
45c01b6a64 Fix collection race condition + search pagination (#540) 2020-05-08 16:51:14 -04:00
Rijk van Zanten
828d81e044 Collection presets (#538)
* Fix table select all

* Fix defaulting + staging changes on new preset

* Navigate to bookmark after creation

* Support exact prop on v-list

* Use exact links in browse

* Show bookmark title when on bookmark

* Force layout refresh on navigation change

* Allow numbers in v-badge

* Add edit bookmark string

* Rename add-bookmark to bookmark-add

* Add bookmark-edit

* Save name changes to bookmark
2020-05-08 15:33:54 -04:00
Rijk van Zanten
a070a25353 Field setup (#536)
* Use the correct table header widths for settings / colections

* [WIP] Rework field setup flow

* Finish setup actions logic

* Remove old field-setup

* Use fixed strategy in popper, render to portal

* Stop relying on no-overflow mode

* Stop propagation of outside click event

* Finish field setup, start on relational setup

* Finish up v-menu

* Add relational m2o markup

* Add relational m2o markup

* Remove empty source, fix codesmell
2020-05-08 14:07:00 -04:00
Rijk van Zanten
0c17735e0e Interface one to many (#533)
* Extract edit modal to standalone component

* Fix creating new item from m2o edit modal

* Rename item-modal to modal-detail

* Extract selection modal in standalone component

* Add required primary-key prop to v-form

* Add inline prop to table

* Fetch items in o2m

* Accept numbers for primary key in v-form

* Use correct collection in render template in m2o

* Render modal detail

* Fix edit existing

* Add add-new

* Do things

* Finish o2m
2020-05-07 10:53:51 -04:00
Rijk van Zanten
70c3f05050 Interface many to one (#524)
* Start on m2o

* Render preview in m2o

* Add icons

* Style inline icons

* Add editing modal

* Disable any linter

* Add add-new button

* Pass existing selection on to layout

* Update v-table to allow for keys-only-selection

* Fix batch on tabular
2020-05-05 14:22:01 -04:00
Rijk van Zanten
622570cc45 Add presets settings (#517)
* Add shared component creation modal

* Add bookmark strings

* Expose save-as-bookmark method

* Fix typing of filter

* Add save bookmark button

* Add presets browse page

* Add select / delete functionality

* Render null value in layout as value-null

* Start on presets detail view

* Render presets detail view

* Save view options correctly

* Add readonly mode to cards layout

* Add layout drawer to presets detail

* Add delete on detail

* Add empty state

* Fix linter warnings
2020-05-04 12:31:11 -04:00
Rijk van Zanten
31ef7a48c9 Various fixes (#515)
* Fix image deselection when newID isn't set

* Fix svg support in image interface

* Render correct title on file library detail

* Default to interfaces based on type

* Remove unused import

* Don't show dropdown indicator on field label when readonly

* Accept datetime_created datetime_updated in datetime interface

* Add reused value-null component

* Fix z-index of v-badge

* Close status on content click

* Move edit button to header on file detail

* Increase tooltip z-index

* Add warning notice to edit image modal

* Fix extra spacing in divider interface

* Use wide style for notifications when drawer is open

* Click on image to open file preview
2020-05-01 18:08:37 -04:00
Ben Haynes
4dabcc6a25 Various style tweaks (#513)
* true title alignment

not sure why, but normal was optically best for me

* flip dropdown arrow when open

* flip dropdown arrow and add dot contrast

* fix icon expanding label height

keep arrow visible when menu open

* global form size and clean-up file preview

* updated console log

WIP — also includes format for warnings, errors, timing, etc

* add form max width

* fix search input width with value

* style chips

* no arguments

* 00 == 60

* update tags/chip styling

* wysiwyg editor style fixes

* conditional formatting

* seconds option and wip 12h time

* even editor tool spacing

* avoid vertical text clipping

* add circle option to image display

* add circle option to user display

* add circle to translations

* add rating display

* remove log

* button vertical alignment

* correct image width

* polish image styles

* Fix datetime interface

* Use flip transition

Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
2020-05-01 16:01:22 -04:00
Rijk van Zanten
27c7c055da Interface image (#510)
* Add format filesize util

* Move and tweak file-preview

* Add file lightbox componetn

* WIP add image interface

* Add download prop option to v-button

* Add active model support to image editor

* Add functionality for buttons

* Add deselect button

* Add upload lang

* Fix translations of upload notifications

* Fix local vs global dropzone

* Add v-upload component

* Finish image interface
2020-04-30 17:01:14 -04:00
Rijk van Zanten
e8206b06a2 Rename compositions to composables (#508)
* Rename compositions to composables

* Rename test helper, replace some other occurances

* Log error to console
2020-04-30 10:15:32 -04:00
Rijk van Zanten
4b7fcb79fa Add reusable image editor modal (#503)
* Install cropperjs

* Add cropper js styles

* Add editing image string

* Track inner active state

* Add temp edit button

* Start on image editor modal

* Add custom icons for image manipulation

* Add image manipulation strings

* Tweak cropper styles

* Remove unused import

* Save as blob

* Expose getItem method for manual refreshes

* Add cache-busting to file preview

* Use new API post endpoint, emit refresh event on success

* Add a cache buster to the image editor
2020-04-29 16:44:34 -04:00
Rijk van Zanten
6ed64a9667 Bookmarks (#494)
* Add support for bookmarks in collection preset composition

* Add strings for bookmark 404

* Use bookmarks prop in collections browse

* Use exact for active link in navs

* Show bookmarks in navigation

* Make bookmark optional in collection preset
2020-04-27 18:59:59 -04:00
Rijk van Zanten
eb129ec750 File preview (#490)
* Don't show filters that are locked

* Change status badge size

* Fix letter spacing

* Optically align title

* Add file-preview at top of files page

* Add missing alt attr
2020-04-27 15:06:19 -04:00
Ben Haynes
65888e7ba3 Various style tweaks (#488)
* secondary action button style

will apply to other modules if we like this

* card styling

filled grid
static gaps
improved selections/hovering

* action button colors

* dialog styling

* updated pagination

* choose layout name

* move page count to footer

* card footer

* correct list group icon orientation

* move card size to header

* header icon color

* radios are not labels

* clean up projcet chooser styling

* don’t collapse pagination when empty

* logout style and tooltips

* correct css variable

* layout translation key

* use general “per page” translation

* hide per page when not in use

also increases min per page from 10 to 25

* more per page fixes

* add regex placeholder

* add new custom grid icons

* new card size toggle and tooltips

* differentiate between inner/outer border radius

WIP

* display icons

* horizontal alignment for status dot

WIP

* beautiful badges

* fix jumping table loader

* show search “x” when minimized

* shorten page count string

* system tooltips

* user menu avatar hover

* edit vs new detail page

don’t show delete if new
rijk might not like my nested ternary

* conditional divider spacing

Co-authored-by: Rijk van Zanten <rijkvanzanten@me.com>
2020-04-27 14:09:40 -04:00
Rijk van Zanten
9e28932a42 Collection display template (#487)
* Add translation strings for adding/editing item

* Add display_template to collection type

* Dont use functional for skeleton loader

* Make title optional and add title slot

* Make title prop optional in private view

* Render -- for null values in render template

* Render display template in header bar

* Render null values in template as subdued --

* Render status dot aligned in the middle

* Fetch latest collections on settings save
2020-04-27 10:50:38 -04:00
Rijk van Zanten
4e7ab8b8a3 Add item count indicator to tabular and cards (#483) 2020-04-24 20:53:56 -04:00
Rijk van Zanten
8498c37431 Info state (#482)
* Render markdown in field notes

* Make add field button full width on data model

* Add no items with cta

* Add no items cta

* Add no results + clear

* Add no collections state
2020-04-24 20:12:51 -04:00
Ben Haynes
b30dd930e7 Various style tweaks (#479)
* secondary action button style

will apply to other modules if we like this

* card styling

filled grid
static gaps
improved selections/hovering

* action button colors

* dialog styling

* updated pagination

* choose layout name

* move page count to footer

* card footer

* correct list group icon orientation

* move card size to header

* header icon color

* radios are not labels

* clean up projcet chooser styling

* don’t collapse pagination when empty

* logout style and tooltips

* correct css variable

* layout translation key

* use general “per page” translation

* hide per page when not in use

also increases min per page from 10 to 25

* more per page fixes

* add regex placeholder

* add new custom grid icons

* new card size toggle and tooltips

* differentiate between inner/outer border radius

WIP

* display icons

* horizontal alignment for status dot

WIP

* beautiful badges
2020-04-24 18:48:05 -04:00
Rijk van Zanten
871cd9c228 Block filters while loading (#478)
* Register filter drawer detail globally

* Add loading state mode to filter drawer detail

* Fix cursor clicking in search-filter

* Move filter drawer detail to layouts

* Fix typing of badge in drawer detail

* Close filter dropdown on content click

* Close project chooser on click outside
2020-04-24 18:23:59 -04:00
Rijk van Zanten
0d01265e9e Fix save-and-stay on new items (#474) 2020-04-24 17:23:11 -04:00
Rijk van Zanten
9138e7ab5b Search input (#473)
* Add search-input component

* Add searchquery support to tabular view

* Add search bar on collections browse

* Debounce input values

* Handle searchQuery in collection preset composition

* Handle searchquery in use-items composition

* Support search query in cards layout

* Add search-input to files/users
2020-04-24 16:27:17 -04:00
Rijk van Zanten
0b05613a55 Add dropdown interface (#461)
* Add show-deselect option to v-select

* Add parse-choices util

* Add dropdown interface

* Add allow-other prop to v-select (single only)

* Check for custom state correctly

* Treat empty custom value as null

* Set full-width to true by default for inputs / selects

* Add allow-other support to multiple dropdown

* Upgrade display value to show item count

* Fix custom deletion

* Fix tests

* Pass allow other on in dropdown interface
2020-04-23 18:16:17 -04:00
Ben Haynes
ae64f20578 Various style tweaks (#449)
* secondary action button style

will apply to other modules if we like this

* card styling

filled grid
static gaps
improved selections/hovering

* action button colors

* dialog styling

* updated pagination

* choose layout name

* move page count to footer

* card footer

* correct list group icon orientation

* move card size to header

* header icon color

* radios are not labels

* clean up projcet chooser styling

* don’t collapse pagination when empty

* logout style and tooltips

* correct css variable

* layout translation key

* use general “per page” translation
2020-04-22 13:19:20 -04:00
Rijk van Zanten
4b2a43aa9d Permissions (#451)
* Start on permissions setup widget

* Calculate toggle states

* Render out statuses details

* Render all sub-toggles

* Rough in grid styling

* Tweak type / structure of permissions array

* Add inline saving for status checkboxes

* Fix popper reference

* Add sub-indicators + add active to list item

* Finish status toggles

* Add saving on column level

* Add border to system section

* Add field blacklist modal

* Make field blacklist work on collection level

* Add indeterminate state to field checkboxes

* Add hover / active state to activator

* Save all statuses to create on collection level too

* Visually align icons

* Account for status mapping without value key

* Style loader to match height of permissions

* Add status modal

* Allow status modal for create permission

* Add collections header

* Increase font-weight of permissions header
2020-04-22 11:46:45 -04:00
Rijk van Zanten
92b9c79669 File library issue (#446)
* Fix default state for file library, dont allow sorting by fake fields

* Fix duplicate collection presets

* Force type field to be fetched in file library

* Fix wrong assignment
2020-04-21 13:20:40 -04:00
Rijk van Zanten
01d8ded4b2 Fix deeply nested folder event and overflow (#445)
* Fix deeply nested folder event and overflow

* Fix code smell
2020-04-21 09:52:47 -04:00
Rijk van Zanten
48e862fe6b Add form to collection detail (#442) 2020-04-20 18:38:33 -04:00
Rijk van Zanten
8bf25d3e3c Files nav (#441)
* Add support for item-group top level links

* Add active prop support to v-list-group

* Add all-files string

* Add files nav

* Fix nav order, render divider only when items exist

* Add add-new-folder flow

* Add add-folder button to header

* Dont unmount nav on refresh of folders

* Fix codesmell
2020-04-20 18:15:55 -04:00
Ben Haynes
6cb4cf2232 Various style tweaks (#427)
* nav list sizing

* less contrast on table load progress

* new data model icon

* fixes all users nav

rijk SAID he fixed… but that’s ok ;)

* lighter module active color

* decrease badge size

* text changes

* new sidebar drawer component styling

* space out filters a bit more

* add auto-save warning to fields setup

* new tabular option icons

* new filter styling

needs formatting and translations for field name tooltips

* form field group styling

WIP — just styling, and needs translations

* don’t let line height be overridden

* interface icons

* button hovers

* divider interface WIP

* lighter highlight

we can try this out — might remove later

* no divider tests

* Fix divider interface

Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
2020-04-20 14:36:59 -04:00
Jacob Rienstra
bf79610219 Text-input / v-input fixes (#386)
* textinput fixes including masking trimming icons and fonts

* removed masked attribute from v-input

* added wrapper div

* ugh

* test fix

* fixed all calls to monospace boolean except on textarea (in separate branch)

* readonly

* Remove unused wrapper div and rename readonly to disabled

* Rename readonly to disabled in story

* Prefer style over inline styles

* Fix codesmell

Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
2020-04-20 10:23:01 -04:00
Rijk van Zanten
3a89dc41f9 Add the cards layout (#430)
* Fix reactivity of currentLayout in drawer detail

* Start on cards layout

* Use dense list items in v-select

* Add cards + size option

* Render cards + files based on options

* Allow modules to set view defaults

* Start on render-template component

* Add get fields from template util

* Use render template component in cards layout

* Render as small icon

* Accept options in display handler function

* Fix type warnings in format title display

* Remove empty styling in render template component

* Account for null values in render template

* Add loading state to cards layout

* Remove type validation in skeleton loader

* Only fetch rendered fields

* Fix resolving of default values for cards module

* Add selection state to cards

* Add selection state to cards

* Make render template reactive

* Implement setup options

* Add disabled support to v-select

* Add fallback icon option + disable fit input when no source

* Add sort header to cards layout

* Remove console log

* Add selection state to cards header

* Fix z-indexing of header menu

* Add pagination to cards layout

* Fix types in field

* Fix type checks in field-setup

* Add role presentation to img

* Remove code smell

* Handle file library gracefully

* Add native lazy loading to images in cards layout

* Render SVGs inline in card
2020-04-18 16:20:00 -04:00
Rijk van Zanten
28a4ad5ec6 Add view type switch (#424)
* Manage view_type through collection preset composition

* Move view type translation

* Add layout drawer detail component

* Use different icon for tabular

* Render view as section in browse sidebar

* Fix sticky header in table

* Sort return statement values 🤓

* Use viewtype picker on users

* Use layout picker on files

* Default to tabular view when invalid is set

* Render view type dynamically based on setting
2020-04-16 16:53:45 -04:00
Ben Haynes
ce9c374876 Various style tweaks (#423)
* nav list sizing

* less contrast on table load progress

* new data model icon

* fixes all users nav

rijk SAID he fixed… but that’s ok ;)

* lighter module active color

* decrease badge size

* text changes

* new sidebar drawer component styling

* space out filters a bit more

* add auto-save warning to fields setup

* new tabular option icons

* new filter styling

needs formatting and translations for field name tooltips

* form field group styling

WIP — just styling, and needs translations
2020-04-16 16:20:23 -04:00
Rijk van Zanten
e3985ad09b Filter (#420)
* Add filter operators

* Render drawer detail hr full width

* Start on filter component

* Add getRelationsForCollection method

* Add all filter logic (no sorting yet)

* Use correct border color for divider by default

* Tweak operator translations

* Add getField action to fields store

* Fetch fieldsinfo in relations get for files

* Use scoped operators, start on type based input

* Add disabled option to v-badge

* Globally register v-badge component

* Add between filter support

* Hide alias fields

* Work debouncing magic

* Add margin beneath filter blocks

* Fix fetching filter count in use-items comp

* Add relational field lookup

and show tooltip with field name in filter section

* Use filters on users / files

* Allow double level filter
2020-04-15 21:15:44 -04:00
Rijk van Zanten
7e2866373d Stores (#417)
* Fix store identifier

* Add relations store

* Remove rolesStore in favor of composition for user nav

* Fix tests
2020-04-14 17:33:26 -04:00
Rijk van Zanten
97c8f763ab Finish settings > datamodel > collections (#414)
* Add missing slot to readme

* Show and order all collections

* Render correct icon for each collection type

* Add ctx menu on collections overview

* Use subdued colors in icons by default

* Add delete collection flow

* Add delete flow

* Move options to separate component

* Add manage / unmanage toggles

* Add collections filter

* Make non-nav list item icons subdued

* Tweak where loader shows up when managing

* Pass item key to v-table
2020-04-14 13:28:39 -04:00
Ben Haynes
57562cffc4 Various style tweaks (#412)
* nav list sizing

* less contrast on table load progress

* new data model icon
2020-04-14 10:17:20 -04:00
Rijk van Zanten
7e98692635 Users nav (#405)
* Fix users-nav + add divider

* Fix project chooser name

* Don't use list item title in nav

* Add divider in users nav

* Fix default size of text
2020-04-13 18:13:50 -04:00
Rijk van Zanten
2c5ce38e65 Small tweaks, large benefits (#404)
* Add 160px bottom padding to all pages

* Force header column to have 24px min width

* Allow resizing of last column in v-table

* Fix table row unwanted spacing + offset 2px

* Add divider to end of drawer detail

* Add down chevron on project chooser hover

* Add support for color accented modules

* Use yellow header icon in settings

* Add link to collections module browse icon

* Dont show all items selected on load v-table

* Add prepend / append slot to v-checkbox

* Add drag handles to field setup settings in tabular

* Fix loading state in table

* Show all resize handles on hover

* Lose breadcrumb in collections module, show singleton title

* Wrap activity icon, render textarea full width

* Dont render comments section on batch

* Allow input to shrink for slots

* Fix cursor on v-selects

* Prevent input usage when they have click events

* Fix margin on divider in fields-management

* Fix drag handles on field selects

* Fix button / divider spacing

* Remove support for divider inset

* Fix test warning

* Fix table-row test

* Fix codesmell

* Fix missing scope attr
2020-04-13 17:15:58 -04:00
Rijk van Zanten
7cba8a8de1 Users nav (#400)
* Add filters-to-query util

* Add all users string

* Suppot filters in tabular layout

* Sync filters with collection presets

* Support filters in use-items composition

* Render users nav + use skeleton loader

* Add list-item-icon type to skeleton loader

* Fix missing loader indicator on table

* Cleanup has click check

* Dont route based on id

* Fix loading state in table

* Revert "Dont route based on id"

This reverts commit 6de7cbe1b801d5e5e267f09a6e77dc73dcc60a37.

* Fix table loading state

* Fix routing for users module

* Force role field to be fetched

* Add roles store

* Dont render avatar until user is known

* Speed up hydration absurd much

* Rely on roles store to prevent nav from loading

* Fix tests
2020-04-13 15:18:54 -04:00
Rijk van Zanten
799681682d Soft delete (#395)
* Use higher res image in module avatar

* Remove glitch

* Add soft delete button / flow

* Fix tests
2020-04-13 11:53:04 -04:00
Ben Haynes
7c0976441d margin, padding, size, and color tweaks (#374)
* margin, padding, size, and color tweaks

* Remove commented out code

* Use pointer-events instead of double click event

* Use v-deep for v-sheet in v-dialog

* Add newline

* Fix stylelint complaint

* Fix tests

Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
2020-04-09 19:27:07 -04:00
Rijk van Zanten
7a2ee0215f Support link-modules and add docs link (#368)
* Allow link type modules

* Add docs module

* Allow buttons to render as <a>

* Update button readme

* Use link buttons in module sidebar when needed
2020-04-09 10:23:07 -04:00
Rijk van Zanten
cf7d25b99f Add roles browse / detail (without permissions) (#364) 2020-04-08 15:53:29 -04:00
Rijk van Zanten
eb7153cbfc Add webhooks settings (#363) 2020-04-08 14:38:03 -04:00
Rijk van Zanten
6979fadb6c Allow hidden modules and add activity module (#362)
* Fix wrong component names

* Hide selection in table when there is no selection prop

* Add activity module

* Support hidden option in module definition
2020-04-08 14:05:44 -04:00
Rijk van Zanten
442ad58ff6 Add files module (#361) 2020-04-08 13:26:43 -04:00
Rijk van Zanten
a9bfa469d9 Add users module (#360)
* Install micromustache

* Add useCollectionPreset composition

* Add detailRoute prop to layouts

Allows for overriding where the detail view is located from the parent

* Add locale translations for users/files/activity

* Update collections module to use new composition / layout prop

* Update useItem useItems to allow for directus_ collections

* Add default width to all fields with no width

* Only fetch comment,create,update,delete activity on detail

* Fix out-transition on sign-out button

* Add users module
2020-04-08 12:35:36 -04:00