EuiPanel can give depth to your container with{' '}
hasShadow while hasBorder can
- add containment. Just be sure not to include too many nested panels
- with these settings.
+ add containment. Just be sure not to include too many{' '}
+ nested panels with these
+ settings.
For instance, only plain or transparent panels can have a border
- and/or shadow. The Amsterdam theme doesn't allow combining
- the hasBorder option with{' '}
- hasShadow. The default theme only allows
- removing the border if both hasShadow and{' '}
- hasBorder are set to false.
+ and/or shadow. The default theme doesn't allow combining the{' '}
+ hasBorder option with{' '}
+ hasShadow.
@@ -15,19 +19,19 @@ export default () => {
- {/* This example only works for the Amsterdam theme. The default theme has `hasBorder={true}` by default. */}
- {isAmsterdamTheme && (
- <>
-
- {'hasBorder={true}'}
-
-
- >
+ {/* This example only works for the default theme. The legacy theme has `hasBorder={true}` by default. */}
+ {!isLegacyTheme && (
+
+ {'hasBorder={true}'}
+
)}
-
- {'hasShadow={false} hasBorder={false}'}
-
+ {/* This example only matters for the legacy theme. The default theme has `hasBorder={false}` by default. */}
+ {isLegacyTheme && (
+
+ {'hasShadow={false} hasBorder={false}'}
+
+ )}