dir-94c21456.js 517 B

1234567891011121314151617181920
  1. /*!
  2. * (C) Ionic http://ionicframework.com - MIT License
  3. */
  4. 'use strict';
  5. /**
  6. * Returns `true` if the document or host element
  7. * has a `dir` set to `rtl`. The host value will always
  8. * take priority over the root document value.
  9. */
  10. const isRTL = (hostEl) => {
  11. if (hostEl) {
  12. if (hostEl.dir !== '') {
  13. return hostEl.dir.toLowerCase() === 'rtl';
  14. }
  15. }
  16. return (document === null || document === void 0 ? void 0 : document.dir.toLowerCase()) === 'rtl';
  17. };
  18. exports.isRTL = isRTL;