Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Scrollable areas - add dynamic shadows based on scroll position

未关闭
#11,817 5 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
5/5
预计耗时
一周以上
新手友好度
30/100
Issue 类型
功能
描述清晰度
需要澄清
活跃度
冷清
技术栈
css, react, typescript
领域
design, frontend

调研方向

从链接的可滚动页面部分 overflow-scroll demo 开始,检查 .pf-m-overflow-scroll 和 .pf-m-shadow-bottom 当前的行为。明确动态阴影应广泛应用,还是仅应用于页面部分,包括对性能的预期以及所需的滚动状态。在开始实现之前就范围和行为达成一致,即视为完成。

由索引模型根据 Issue 内容生成。

描述

PF Team Stale

From @jamestalton, I wanted to create an issue to track a request I've heard from James a few times. It would be super cool if PF was able to add shadows to scrollable regions dynamically. A good example we could currently work with is scrollable page sections. You designate a page section as .pf-m-overflow-scroll, and by default, it looks like any other page section. However, if its content is taller than the section, it will automatically add a scrollbar and the content becomes scrollable. PF could detected that there is overflow and added a shadow dynamically. Currently users can add shadows themselves by adding .pf-m-shadow-bottom (one for a top shadow, too) to the preceding page section, but that class adds a static shadow. If you add it because the section below has the potential to scroll, but doesn't scroll because there is no overflow content, the shadow appears unnecessarily.

Some questions:

  • Currently a user could wire this up themselves, but should PF provide this ability?

  • Would this be enabled for all scrollable regions? Sounds like that has the potential to create a lot of work to implement/maintain.

  • Is there any kind of performance cost?

  • Are there other cases for dynamic shadows - for example, adding a shadow only once you've scrolled a little bit? What's the LEO for that and does it come with performance costs?

Anything else you'd like to add @jamestalton?


Jira Issue: PF-1775

主要语言
TypeScript
星标
862
派生
392
平均合并
4 天 8 小时
30 天内合并 PR
9

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

patternfly/patternfly-react 的其他 Issue

查看 patternfly/patternfly-react 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。