Giter Site home page Giter Site logo

cipchk / ngx-weui Goto Github PK

View Code? Open in Web Editor NEW
427.0 39.0 103.0 13.56 MB

WeUI for angular

Home Page: https://cipchk.github.io/ngx-weui/

License: MIT License

JavaScript 0.82% TypeScript 83.83% CSS 4.28% HTML 10.84% Shell 0.23%
weui angular-weui angular-components angular-library weui2 lvy angular angular9

ngx-weui's People

Contributors

cipchk avatar cxy930123 avatar fourcels avatar mo-gong avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ngx-weui's Issues

Pull To Refresh

我正在使用Pull To Refresh组件实现一个下拉加载更多的功能,这个组件有没有设置disabled的方法。我想在没有更多数据时禁用它。类似微信聊天下拉加载数据。

swiper 手机端无法滑动

swiper 手机端无法滑动,显示的是最后一个slide-item:
场景描述:在使用 weui-tabbar 时
image

第一个 weui-tab 的 weui-swiper 正常使用,第二个 就会出现 无法滑动,只显示出 最后一个 slide-item

ngx-weui 的兼容性如何?

在 ios safari 上测试OK,在android 的 browser 上测试,有问题!想问一下,ngx-weui 的兼容性如何!

作者,picker的需求来了。

地区插件能否增加一个显示列数的选项。(需求:一份地区三级数据,但项目中有的用到一级,有的用到2级,有的用到3级。)

日期选择也是,有的我是选择 年-月 还有一个年-月-日-时。
(日期也可以用我显示几列,设置dateTime 后再用列数控制)

grid升级需求

建议把grid封装成组件:
1:支持路由跳转
2:每行grid格式不是固定的3个,支持栅格化布局

Uploader

我有一个Component 里面有个属性叫model,调用Uploader时我想将这个model的某个属性放到params中传到后台,但是在UploaderOptions里面访问不到这个model属性,请问该如何才能访问到这个model属性的值呢。。

DatePicker问题

ngx-weui是用npm安装的,版本为1.0.8,浏览器是Chrome
这是我使用DatePicker的代码

<weui-date-picker type="date" [(ngModel)]="event.expTime" name="expTime"></weui-date-picker>

在使用DatePicker时,遇到一个问题
image
追踪到代码里,是picker-data.component.js文件72行,this._value没有getFullYear()等Date对象才有的方法。我打印了this._value,值为2017-07-13。问题在于这里的this._value不是Date对象,而是一个字符串。将62行代码改成

if (!this._value)
     this._value = new Date();
else
     this._value = new Date(this._value)

即可解决问题。但是我不知道这里为什么会出现这个问题。

同时还发现了另外一个问题:
我的代码里使用了ngIf来控制DatePicker的显示和隐藏。其中一个功能是当选中一个选项,DatePicker才会出现,但是这里也会出错,我看了一下,拿到的this._value是0000-00-00,这是一个无效的Date。导致出错。

最后找到215行:

    DatePickerComponent.prototype.writeValue = function (value) {
        if (value) {
            this._value = value;
            this.genGroups();
        }
    };

这里的this._value拿到的就一直是字符串(包括非法的时间字符串),但是我不知道这个方法是什么时候调用的。

weui-tabbar 下 的 weui-tab 初始化导致 swiper失效。

weui-tabbar 下 的 weui-tab 初始化导致 swiper失效:
app.component.html:
image
app.component.ts:
image
把两个 swiper 分别放在第一个 weui-tab 和 第二个 weui-tab,如果默认初始化激活的是第一个weui-tab 则 第一个的 swiper 正常,第二个swiper 不正常。如果给第二个weui-tab 加上 [active]='true',是默认激活的是 第二个weui-tab 则第二个swiper 正常,第一个swiper 不正常!

swipe单元滑块打包有问题

ng build --prod 打包时报错
qq 20170719095847

看这意思应该是说SwipeDirective重复declarations了。
但是我不declarations它的话又没有效果。
十万火急!

About Toast component

How do I close a toast manually rather than a timeout setting? What I want is to close a toast with the type of loading only after my api call, then I'm able to coordinate api response and UI updating, I don't find a close method from your document, please advice, thank you!

image

什么时候可以出一个支持到镇街的组件,city-picker 只支持到区级

export class CityPickerComponent implements ControlValueAccessor, OnDestroy {
...
writeValue(value: any): void {
        if (value) {
            this._value = value;
            if (this._value && this._value.length === 6) {
                this.valueToSelect(this._tmpData, this.dataMap.items, 1);
                this.parseData(this._tmpData, this.dataMap.items, this._selected);
            }
        }
    }
...
}

街镇级类似: 440605011000 十二位数。

已提交一个 pull request,请看看符不符合您的代码设计。

CityPicker

能否获取到省市区各自的ID?

Pull To Refresh组件问题

该组件不会判断滚动条位置,只要下拉就会触发。导致在移动端和滚动条下拉产生冲突。
该组件配合上拉加载更多使用时,无法下拉查看前面的数据。

日期插件(也算需求吧,有时间再看吧)

(以下两个都是用服务实现的)
1.日期插件快速点击。会出现一个以上的弹出窗
(这个通过防止表单重复提交,加个变量,也可以处理)
2.日期插件点击后,不点击确定或取消,通过浏览器导航返回上一页。
会出现弹出层还在的情况
我用ng1开发的时候。用的其他弹出窗插件也有这个情况,我是在路由监听那块DOM移除的
看服务没有提供销毁的方法(有的话,在component 的 ngOnDestroy 调用销毁)

win10 下 npm start 报错

1、npm install 会有以下提示:
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules\chokidar\node_modules\fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"}) npm WARN [email protected] requires a peer of @angular/[email protected] but none was installed. npm WARN [email protected] requires a peer of @angular/[email protected] but none was installed. npm WARN [email protected] requires a peer of @angular/[email protected] but none was installed. npm WARN [email protected] requires a peer of @angular/[email protected] but none was installed. npm WARN [email protected] requires a peer of @angular/[email protected] but none was installed.

2、npm start 会有以下提示:
`

[email protected] start F:\Framework_Angular2\ngx-weui
ng serve --aot --host 0.0.0.0

** NG Live Development Server is listening on 0.0.0.0:4200, open your browser on http://localhost:4200 **
Date: 2017-09-03T22:45:10.110Z
Hash: a4971ddc81d82022fa14
Time: 7344ms
chunk {inline} inline.bundle.js, inline.bundle.js.map (inline) 5.83 kB [entry] [rendered]
chunk {main} main.bundle.js, main.bundle.js.map (main) 8.7 kB {vendor} [initial] [rendered]
chunk {scripts} scripts.bundle.js, scripts.bundle.js.map (scripts) 328 kB {inline} [initial] [rendered]
chunk {styles} styles.bundle.js, styles.bundle.js.map (styles) 31.6 kB {inline} [initial] [rendered]
chunk {vendor} vendor.bundle.js, vendor.bundle.js.map (vendor) 1.54 MB [initial] [rendered]

ERROR in Error encountered resolving symbol values statically. Could not resolve ngx-weui relative to F:/Framework_Angular2/ngx-weui/demo/src/app/shared/shared.module.ts., resolving sym
bol SharedModule in F:/Framework_Angular2/ngx-weui/demo/src/app/shared/shared.module.ts, resolving symbol SharedModule in F:/Framework_Angular2/ngx-weui/demo/src/app/shared/shared.modul
e.ts, resolving symbol SharedModule in F:/Framework_Angular2/ngx-weui/demo/src/app/shared/shared.module.ts
ERROR in ./demo/src/main.ts
Module not found: Error: Can't resolve './$$_gendir/app/app.module.ngfactory' in 'F:\Framework_Angular2\ngx-weui\demo\src'
resolve './$$_gendir/app/app.module.ngfactory' in 'F:\Framework_Angular2\ngx-weui\demo\src'
using description file: F:\Framework_Angular2\ngx-weui\package.json (relative path: ./demo/src)
Field 'browser' doesn't contain a valid alias configuration
after using description file: F:\Framework_Angular2\ngx-weui\package.json (relative path: ./demo/src)
using description file: F:\Framework_Angular2\ngx-weui\package.json (relative path: ./demo/src/$$_gendir/app/app.module.ngfactory)
no extension
Field 'browser' doesn't contain a valid alias configuration
F:\Framework_Angular2\ngx-weui\demo\src$$_gendir\app\app.module.ngfactory doesn't exist
.ts
Field 'browser' doesn't contain a valid alias configuration
F:\Framework_Angular2\ngx-weui\demo\src$$_gendir\app\app.module.ngfactory.ts doesn't exist
.js
Field 'browser' doesn't contain a valid alias configuration
F:\Framework_Angular2\ngx-weui\demo\src$$_gendir\app\app.module.ngfactory.js doesn't exist
as directory
F:\Framework_Angular2\ngx-weui\demo\src$$_gendir\app\app.module.ngfactory doesn't exist
[F:\Framework_Angular2\ngx-weui\demo\src$$_gendir\app\app.module.ngfactory]
[F:\Framework_Angular2\ngx-weui\demo\src$$_gendir\app\app.module.ngfactory.ts]
[F:\Framework_Angular2\ngx-weui\demo\src$$_gendir\app\app.module.ngfactory.js]
[F:\Framework_Angular2\ngx-weui\demo\src$$_gendir\app\app.module.ngfactory]
@ ./demo/src/main.ts 4:0-74
@ multi webpack-dev-server/client?http://localhost:4200 ./demo/src/main.ts

webpack: Failed to compile.
`
请问下该怎么解决?谢谢

Uploader

UploaderConfig:auto: true不起作用

swiper不能用

Can't bind to 'options' since it isn't a known property of 'weui-swiper'.

CityPicker初始化

CityPicker默认无法显示ngModel绑定值对应的lable,显示后也没有默认选中ngModel绑定值。
ngModel绑定值、data数据值我写死了都没有默认选中的效果。

weui-picker

如果是多列数据(2列以上),[defaultSelect] 和 [(ngModel)]共存的话有点问题。
[defaultSelect] 以这样的格式([defaultSelect]=“[[5],[9]]”)来控制两列数据默认选中是没有问题,只是input不会把选中的值展示出来;
qq 20170620093521

[(ngModel)] 绑定值是最后一列的选中值。input是把值显示出来了,但并不是预期的结果。

qq 20170620093705

可能通过调整数据格式可以达到我的目的?

data:

[
 [
  {label: '1', value: 1},
  {label: '2', value: 2},
  {label: '3', value: 3},
              ...
 ],
 [
  {label: '1', value: 1},
  {label: '2', value: 2},
  {label: '3', value: 3},
             ...
 ]
]

weui-input 验证机制问题

刚打开页面就开始验证 出现错误信息,体验很不好!我看了API 不知道怎么去处理!
image
正则表达式,也无效!

dialog自定义html 无法展示<input>?

dialog自定义html 无法展示?
this.config.content = <p align="left">请输入</p> <input type="text" value="text" /> (这里是有加`的)
显示不出 input呢,有没有什么好提议?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.