jhu-idc / iDC-general

Contains non-code-base specific tickets relating to the Islandora8 for Digital Collection project
0 stars 0 forks source link

Set up foundation for public facing UI #100

Closed cyork closed 3 years ago

cyork commented 3 years ago

Acceptance criteria:

There is setup work to do on the project once the base repository has stabilized. This involves working to install the tailwind UI library whether by module or manual installation. It also involves installing stimulus.js for use of javascript without decoupling the UI. There are Drupal/php settings files that should be edited to enhance debugging drupal output. The public theme will almost certainly be different than the internally facing admin theme. We should land on an acceptable theme for admin UI.

jabrah commented 3 years ago

Choosing a theme

Besides the admin theme, we'll also need to choose (or choose not to use) a base theme for our custom theme, which ties into general public facing templates. I'm not especially excited about any options that I've come across, however I also think that not using a base theme will be prohibitively expensive in terms of development time. While playing around with Drupal, I basically started highly customizing Classy, one of the default themes that ships with Drupal.

IMO, I think classy would be a fine starting point for us. My main concern has to do with Drupal best practices. Because of my inexperience with Drupal, I expect much of what I (we) develop to end up being "bad" practice among the Drupal community. I don't expect to share our theme with the Drupal community, so best practices may not necessarily be as important, but it may make future maintenance more challenging.

We might check out the Bootstrap Drupal theme for coding practices.

Dealing with dependencies

"Installing" JS or CSS dependencies should be straightforward, since they just need to be declared in our theme's info.yml file and the dependencies will automatically be included in the Drupal UI. There are some other development questions such as setting up asset bundling, if desirable, and dev vs prod environments.

UI Project Layout

We need to formalize project/repository structure, especially when dealing with custom JS. Presumably, we'll develop our custom JS components directly in the custom theme to allow for much faster iteration. However this approach does have some drawbacks. I'm not necessarily advocating different approaches described below right now, but they may be worth considering in the future after development stabilizes somewhat.

Tasks

jabrah commented 3 years ago

Temporary repo location: https://github.com/jabrah/idc-ui-theme

Being done along side #213