idux icon indicating copy to clipboard operation
idux copied to clipboard

API 一致性

Open danranVm opened this issue 4 years ago • 2 comments

  • [ ] I have searched the issues of this repository and believe that this is not a duplicate.

表单

  • 所有表单组件都应该实现 control API

方向和位置

  • align : 表示文字的对齐方式,可选项: start , end (不要再使用 left, right 了)

    • &-start {
        text-align: start;
      }
      
      &-end {
        text-align: end;
      }
      
  • placement : 表示组件对齐或者弹出的位置,可选项: topStart, top, topEnd, startTop, start, startBottom..., bottom..., end...

  • vertical : 表示垂直方向,通常组件都是默认水平方向,当设置 vertical = true 的时候,表示垂直方向。

是否带边框

  • borderless : boolean 类型,为 true 时表示无边框
    • 可选 class, ix-xxx-bordered, ix-xxx-borderless
    • class 其实也想统一成一个的,但是发现有些场景统一成一个不太好处理,看看有没有更好的方案。

danranVm avatar Sep 06 '21 06:09 danranVm

Translation of this issue:

API consistency

  • [] I have search the [Issues] (https://github.com/iduxfe/idux/issues) of this repository and believe That this is not a duplicate.

Direction and location

  • Align: Expressing the alignment of the text, option: Start, End (Do not use left, right)

    • &-start {
        text-align: start;
      }
      
      &-end {
        text-align: end;
      }
      
  • Placement: Represents the position of the component alignment or pop-up, option: Topstart, top, topnd, right ..., bottom ..., Left ...

    • The default value provided by the component, use the value of the top and bottom starts, this can not consider the switching when RTL
  • Direction: Indicates horizontal or vertical direction: Optional: Horizontal, horizontal

Border Related

  • Borderless: Boolean type, indicates boundless frame for true
    • Optional Class, ix-xxx-bordered, ix-xxx-boorderless
    • Class actually wants to unify one, but find some scenes to unify a unhappy process, see if there is a better solution.

idux-bot[bot] avatar Sep 06 '21 06:09 idux-bot[bot]

re #466

danranVm avatar Oct 09 '21 06:10 danranVm