Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Until IE Dead #75

Open
JaeYeopHan opened this issue Jan 22, 2021 · 2 comments
Open

Until IE Dead #75

JaeYeopHan opened this issue Jan 22, 2021 · 2 comments
Labels
related:css Related css related: web Related everything of web type: material For sources

Comments

@JaeYeopHan
Copy link
Owner

1. Table border-collapse issue

/*
  when border-collapse is 'collapse',
  cannot apply border style to th, tr element
  so...
*/

export const tableBorderWhenIE = isIE()
  ? css`
      border-collapse: separate;
      border-spacing: 0;
    `
  : null;
@JaeYeopHan JaeYeopHan added related: web Related everything of web related:css Related css type: material For sources labels Jan 22, 2021
@JaeYeopHan
Copy link
Owner Author

@JaeYeopHan
Copy link
Owner Author

3. Element.scrollTo

image

interface Options {
  x?: number;
  y?: number;
  behavior?: 'smooth';
}

export function elementScrollTo(element: Element, { x, y, behavior }: Options) {
  if (isIE()) {
    if (x != null) {
      element.scrollLeft = x;
    }
    if (y != null) {
      element.scrollTop = y;
    }
    return;
  }
  element.scrollTo({ left: x, top: y, behavior });
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
related:css Related css related: web Related everything of web type: material For sources
Projects
None yet
Development

No branches or pull requests

1 participant