bug: The ion-no-padding class is not overriding the ion-list padding

未关闭
#30,521 4 条评论 3 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
48/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
停滞
技术栈
angular, css, typescript
领域
frontend

调研方向

打开链接的 StackBlitz 复现,并从 src/app/example.component.html 开始,然后检查 ion-list 和 ion-no-padding 的计算样式。确认冲突的 padding 规则,并验证应用该类时复现中没有 padding。

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

描述

package: core type: bug
Prerequisites
Ionic Framework Version

v8.x

Current Behavior

The ion-no-padding class is not overriding the ion-list padding

Image

Expected Behavior

When setting the class ion-no-padding it should not have padding.

Steps to Reproduce

See the CSS in the example: https://stackblitz.com/edit/wdmx2ux4?file=src%2Fapp%2Fexample.component.html

Code Reproduction URL

https://stackblitz.com/edit/wdmx2ux4?file=src%2Fapp%2Fexample.component.html

Ionic Info
Ionic:

   Ionic CLI                     : 7.2.1
   Ionic Framework               : @ionic/angular 8.6.2
   @angular-devkit/build-angular : not installed
   @angular-devkit/schematics    : 19.2.14
   @angular/cli                  : 20.0.4
   @ionic/angular-toolkit        : 12.2.0

Capacitor:

   Capacitor CLI      : 7.4.0
   @capacitor/android : 7.4.0
   @capacitor/core    : 7.4.0
   @capacitor/ios     : not installed

Utility:

   cordova-res : not installed globally
   native-run  : 2.0.1

System:

   NodeJS : v22.13.1
   npm    : 11.4.2
   OS     : Windows 10
Additional Information

No response

主要语言
TypeScript
星标
52.8k
派生
13.3k
平均合并
3 天 1 小时
30 天内合并 PR
86

环境准备

从这里开始

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

ionic-team/ionic-framework 的其他 Issue

查看 ionic-team/ionic-framework 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

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