Code Monkey home page Code Monkey logo

unl_five's People

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

unl_five's Issues

Required text needs to be inverse in settings tray

Currently, when a field is designated as required, the required markup is correctly added by unl_five_preprocess_form_element(); however, in the settings tray, it needs to displayed in inverse:

image

In unl_five_preprocess_form_element(), it's not possible to know if the settings tray is involved not. For that matter, I'm not sure if there's a good programmatic way to conditionally add the dcf-inverse class. It might be the case where CSS is the solution.

Add preconnect HTTP header for cloud typography

what was done on the 7 branch:

function unl_five_html_head_alter(&$head_elements) {
  // Add a preconnect HTTP header for Cloud Typography.
  drupal_add_http_header('Link', '<https://cloud.typography.com>; rel=preconnect');

Ability to set sidebar classnames in 5.0

In the 4.1 appearance tab, there are fields where you can set the classname for grid columns when there is a sidebar.

image

These fields aren't there in 5.0, and I think it would be nice to be able to switch it to a 3/4 + 1/4 column grid instead of 2/3 + 1/3.

image

Also, I just noticed that the "disable drilldown menu" isn't there anymore either โ€” not sure if that will impact sites as well.

Load amd-enable.js after all other Drupal JS

unl_five loads amd-disable.js before Drupal loads the rest of its JS libraries. amd-ensable.js is loaded in the middle of the Drupal these library loads, not after all of them. Both are loaded as Drupal libraries with a large negative weight used for amd-disable.js. The theme currently attempts to use unl_five_js_alter() to set a large positive weight for amd-enable.js; however, this is not an effective method to move the library lower in the load order. In fact, there doesn't appear to be a way to load a JS library last. Drupal uses dependencies to determine load order. The only way to ensure amd-enable.js loads last is to declares everything that loads before it as dependencies. This of course means that all JS loads all the time. This issue sums it up nicely: Loading a custom library after all other libraries got loaded.

The issue was noticed when trying to use the Admin Toolbar module with the unl_five theme.

The proposed solution is to remove amd-enable.js from unl_five's 'amd' library and hardcode it in html.html.twig.

unl_five.libraries.yml:

  amd:
    version: VERSION
    js:
      js/amd-disable.js: { weight: -999 }
-     js/amd-enable.js: { }   

html.html.twig:

  {{ page_bottom }}
  {% include "/wdn/templates_5.0/includes/global/noscript.html" %}
  {% include "/wdn/templates_5.0/includes/global/js-body.html" %}
  <!-- InstanceBeginEditable name="jsbody" -->
  <js-bottom-placeholder token="{{ placeholder_token }}">
+ <script src="/{{ directory }}/js/amd-enable.js"</script>
  <!-- InstanceEndEditable -->
  </body>
  </html>

Serif Font Not Displaying in CKEditor

When an editor add the 'Serif' style to text in CKEditor, the correct class is added; however, the font remains unchanged visually. This is because the 'wdn-font-serif' library needs to be loaded.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.