Skip to content
This repository has been archived by the owner on Jun 29, 2023. It is now read-only.

Bug: calcite-fab - issue with z-index #1000

Closed
AdelheidF opened this issue May 27, 2020 · 15 comments
Closed

Bug: calcite-fab - issue with z-index #1000

AdelheidF opened this issue May 27, 2020 · 15 comments
Assignees
Labels
4 - verified bug Something isn't working
Milestone

Comments

@AdelheidF
Copy link

AdelheidF commented May 27, 2020

Summary

z-indexed content inside components can conflict with things like the sticky fab.
Find a generic solution as we'll probably see other widgets that utilize z-index, e.g. a slider with multiple handles.

Actual Behavior

Expected Behavior

No such conflicts.

Reproduction Steps

  1. add a z-indexed thing to a panel
  2. add a calcite-fab in the panel's fab slot.
  3. panel should have enough content above the z-indexed thing to make the panel scroll and to place the z-indexed thing under the fab when it's acting sticky.
  4. make it so the z-indexed thing is under the fab slot

Relevant Info

@AdelheidF AdelheidF added bug Something isn't working 0 - new labels May 27, 2020
@AdelheidF AdelheidF changed the title Bug: caclite-fab - issue with z-index Bug: calcite-fab - issue with z-index May 27, 2020
@asangma
Copy link
Contributor

asangma commented May 28, 2020

@jcfranco @driskull @kat10140 Would y'all agree that setting the z-index to 5 is a good approach?

@asangma asangma added this to the Marceline milestone May 28, 2020
@driskull
Copy link
Member

Can we try setting position:relative on the container for the slot and a zindex if needed? We don't want to have to compete with whatever they put in the slot. We should just have the fab always be above it.

@AdelheidF
Copy link
Author

The container of the fab is a flow-item. If I set position:relative and z-index doesn't change anything.

http://devext.arcgis.com/apps/mapviewer/index.html?url=https://services1.arcgis.com/4yjifSiIG17X0gW4/arcgis/rest/services/FatalAccidents2017/FeatureServer/0
Click on Filter and add 2-3 expressions.

@driskull
Copy link
Member

@AdelheidF I'm talking about setting the position of the fab container within the component. We should try setting position relative on that and handling any zIndex issues so we don't have to worry about user zIndexes.

@asangma
Copy link
Contributor

asangma commented May 28, 2020

@driskull Hmm...we're using position: sticky for the container of the fab slot.

@driskull
Copy link
Member

yeah, just make sure that the container it's inside has a position relative

@driskull
Copy link
Member

We handled this same scenario in the scrim component

@asangma
Copy link
Contributor

asangma commented May 28, 2020

Got it.

@asangma
Copy link
Contributor

asangma commented May 28, 2020

Applying position: relative to various things is maybe not working. For now though, Jonathan will be removing z-index from the slider handle for when there's only one handle. This will take care of the specific problem, but we may see other z-index issues in the future.

@AdelheidF I'm going to edit the issue to be general to any z-indexed thing. Cool?

@driskull
Copy link
Member

@driskull
Copy link
Member

@asangma
Copy link
Contributor

asangma commented May 28, 2020

I'll give it a try @driskull .

@AdelheidF
Copy link
Author

Try putting position: relative and z-index: 0 on #feature-filter-expressions.

That fixed it for my case.

@asangma
Copy link
Contributor

asangma commented May 29, 2020

Thanks @AdelheidF!

@asangma asangma modified the milestones: Marceline, Neptr May 29, 2020
driskull added a commit that referenced this issue Jun 5, 2020
driskull added a commit that referenced this issue Jun 5, 2020
…n slot content. (#1010)

* calcite-fab - issue with z-index #1000

* review fixes!
@driskull driskull assigned AdelheidF and unassigned asangma Jun 5, 2020
@jcfranco
Copy link
Member

jcfranco commented Oct 7, 2020

Per the above conversation, closing as verified.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
4 - verified bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants