Skip to content

Commit

Permalink
Update utils.ts
Browse files Browse the repository at this point in the history
## Summary

Fixes mdn/browser-compat-data#16839

### Problem

If there is support without a prefix, altname, or flag, even if there is a note indicating a minor limitation with that support, don't show the symbol indicating the need fro a flag, altname, or prefix.

### Solution

Check for support without major limitations, not just support without limitations
  • Loading branch information
danielhjacobs authored Jul 5, 2022
1 parent 3e84a07 commit f719db4
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ export function isOnlySupportedWithAltName(
return (
support &&
getFirst(support).alternative_name &&
!asList(support).some((item) => isFullySupportedWithoutLimitation(item))
!asList(support).some((item) => isFullySupportedWithoutMajorLimitation(item))
);
}

Expand All @@ -116,7 +116,7 @@ export function isOnlySupportedWithPrefix(
return (
support &&
getFirst(support).prefix &&
!asList(support).some((item) => isFullySupportedWithoutLimitation(item))
!asList(support).some((item) => isFullySupportedWithoutMajorLimitation(item))
);
}

Expand All @@ -126,7 +126,7 @@ export function isOnlySupportedWithFlags(
return (
support &&
getFirst(support).flags &&
!asList(support).some((item) => isFullySupportedWithoutLimitation(item))
!asList(support).some((item) => isFullySupportedWithoutMajorLimitation(item))
);
}

Expand Down

0 comments on commit f719db4

Please sign in to comment.