salt-ui / saltui Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
功能需求
//g.alicdn.com/platform/tingle-ui/2.2.3/salt-ui.min.js
安卓手机会出现,有的时候快,有的手机慢
安卓手机
searchbar 搜索结果的列表,在输入框输入内容时,键盘会弹出。当收起键盘的时候,可以看到 class t-search-bar-list 的 css 属性 position: fixed; 当键盘收起的过程中,可以看到 t-search-bar-list 覆盖元素下的 那部分内容
import Icon from ' salt-icon/dist/Symbol';
render() {
return <Icon name='icon-name'/>
}
<SearchBar.WithContainer
onSearch={(value)=> {
console.info(`Do search>>${value}`);
}}
>
{this.renderSearchResult()}
</SearchBar.WithContainer>
仅保留日历面板,支持选择单个日期、日期区间
移除了如下功能:
还移除了:
其它,请看下面的 history
删除
pushLoadTip
cache
clearCache
方法增加
refreshing
loading
noMore
运行机制变动
tingle-scroll-view
封装实现,去除了 iscroll
的依赖onLoad
回调分解为两个方法:onRefresh
和 onLoad
。分别对应下拉刷新和触底加载的回调。注意事项
onRefresh
和 onLoad
改为 Boxs
SearchBar组件用到了hash,这个会造成单页面应用的路由混乱
请按照以下模板填写
3.x
这里又提一个Tab控件的问题。带有showScroll属性的Tab控件,在同一页面由于其他事件触发了Tab.Item个数变化后,宽度没有调整。
例子:http://codepen.io/LiangZugeng/pen/bqjMrV
第一次渲染只有一个Tab.Item,点击按钮后重新生成tabs数组,这次渲染有10个Tab.Item,可以看出再次Render以后Tab可见的Item还是一个(title改变了),但剩下的9个被折行了,看不见。
CheckboxField选中完成后,slotText空字符串显示不对
3.1.17
Windows 10
> node -v
v8.9.0
> npm -v
5.5.1
---
package.json
...
"dependencies": {
"react": "^16.1.1",
"react-dom": "^16.1.1",
"react-scripts": "1.0.17",
"saltui": "^3.1.17"
}
...
import React, { Component } from 'react';
import logo from './logo.png';
import './App.css';
import { Button } from 'saltui';
class App extends Component {
render() {
return (
<div className="App">
<header className="App-header">
<img src={logo} className="App-logo" alt="logo" />
<h1 className="App-title">欢迎使用SaltUI!</h1>
</header>
<p className="App-intro">
<Button type="primary">一级按钮</Button>
</p>
</div>
);
}
}
export default App;
在public/index.html
引入nowa模板的在线资源
<script src="//g.alicdn.com/platform/c/??react/0.14.3/react-with-addons.min.js,react/0.14.3/react-dom.min.js,react-router/2.0.0/umd/ReactRouter.min.js,fastclick/1.0.6/lib/fastclick.min.js,lie/3.0.2/dist/lie.polyfill.min.js,salt-router/0.0.2/salt-router.min.js"></script>
pm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated [email protected]: express 2.x series is deprecated
npm WARN deprecated [email protected]: connect 1.x series is deprecated
npm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated [email protected]: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.
npm ERR! code E404
npm ERR! 404 Not Found: @ali/gitlab-apis@^2.1.0
npm ERR! A complete log of this run can be found in:
see title
3.1.15
SelectField滑动选择时,整个表单跟着滑动。
请按照以下模板填写
2.2.3
crumbs显示中的>需要提供一个配置项来修改内容例如改成:/
tabbar组件对图标替换中,包含了图片地址url的判断,导致如果引入的图片是base64编码后的图片,那么就无法显示替换后的图片了。
请按照以下模板填写
2.2.3
crumbs里的>能否提供一个配置项可以修改例如改成“/”
我在一个页面嵌套使用了带有showScroll属性的控件,控件由代码生成,基本的结构为:
Tab
|-Tab.Item
|-Tab
|-Tab.Item
|-Tab.Item
|-Tab.Item
|-Tab
|-Tab.Item
|-Tab.Item
如果没有showScroll属性,在切换parentTab的Item时,此Tab.Item下的Tab显示正常(由于没有使用showScroll,tab.item只显示了第一个字符,这不是问题)。但把parentTab和childTab都加上showScroll属性时,只有第一个parent Tab.Item下的Tab显示正常,其他parent Tab.Item下的Tab都只显示第一个Tab.Item。参见附图。
Repro代码地址:https://github.com/LiangZugeng/saltUITabIssue3Repro
附图1:没有使用showScroll属性,第一个parent Tab.Item为激活状态:
附图2:没有使用showScroll属性,第3个parent Tab.Item为激活状态:
请按照以下模板填写
3.1.31
react 0.14.9
chrome,win7 使用creact-react-app 创建的项目
页面中引入 import Dialog from 'saltui/lib/Dialog'
在点击事件中
addNurse() {
Dialog.alert({
title: '测试',
content: '我是 Dialog.alert 的调用',
onConfirm() {
console.log('alert confirm');
},
});
}
<button key="aler" onClick={this.addNurse.bind(this)}>add person</button>
报以下错误:
index.js:2177 Warning: React.createElement: type should not be null, undefined, boolean, or number. It should be a string (for DOM elements) or a ReactClass (for composite components). Check the render method of Dialog
.
请按照以下模板填写
3.1.14
我没有找到声明文件呢,是否支持Typescript呢?
salt-tab@^2.1.3
钉钉 4.2.0
ios 11.1.2
style="transform:translateX(0%) translateZ(0);-webkit-transform:translateX(0%) translateZ(0);-moz-transform:translateX(0%) translateZ(0);"
请按照以下模板填写
请按照以下模板填写
使用nowa创建的新工程,react是0.14.3版本,是否可以考虑升级一下react/react-dom/react-router等版本
连续的连个toast ,第一个未结束,第二个又show 出来,在展示的时候会 闪烁 消失一下 又 显示。
同一个页面,并列使用多个带有showScroll属性的Tab控件,结构为:
<Tab showScroll><Tab.Item/><Tab.Item/></Tab> <Tab showScroll><Tab.Item/><Tab.Item/></Tab>
当第二个Tab控件的Item元素的总宽度超过第一个Tab控件的Item元素总宽度太多时,第二个Tab控件的后面一些Item将会被换行,又由于Tab的高度固定,所以从界面上来看后面的这些换行的Item感觉就像是没被渲染或者丢失了。
附图:第二个Tab应该显示到30,但最后一个显示的元素为28
解决方案已经由@光弘 通过钉钉提供,在第二个和以后的Tab上加上key属性并赋不同的值。
请修复此bug。
请按照以下模板填写
3.1.31
chrome,win7
https://codepen.io/smilexlong/pen/XVKqEa
引用IconButton组件会报 Failed propType: Required prop children
was not specified in IconButton
当instantSearch设置为false时,我空搜索后没有反应不触发onSearch事件,只有有值的时候才会触发搜索事件
https://codepen.io/anon/pen/XVjgXQ?editors=1111
请按照以下模板填写
3.1.11
请按照以下模板填写
3.1.13
增加较多的选项,使选项可以滚动
期望选项可以滚动,实际无法滚动
推测与 iscroll 的使用有关。
你可以在这里提交你的 CodePen 链接以及描述复现的步骤
search-bar组件 placeholder字段超长的时候
如题,稍微用力就会触发点击事件而跳转
https://salt-ui.github.io/components/tingle-tab scroll参数不对。
I have the problem when i start the code npm run tnpm-dep
:
events.js:160
throw er; // Unhandled 'error' event
^
Error: spawn tnpm ENOENT
at exports._errnoException (util.js:1022:11)
at Process.ChildProcess._handle.onexit (internal/child_process.js:193:32)
at onErrorNT (internal/child_process.js:359:16)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
at Module.runMain (module.js:606:11)
at run (bootstrap_node.js:394:7)
at startup (bootstrap_node.js:149:9)
at bootstrap_node.js:509:3
some idea?
请按照以下模板填写
3.1.17
see here: Calendar/day/CascadePanel.jsx#L118-L120
Q: 组件库怎么使用?
A: 请看一下这里的开始使用文档,https://salt-ui.github.io/ ,saltui 是基于 React 的 UI 组件库,需要前端知识支撑。React 相关的基础知识,请自行学习。
Q: 我有组件使用上的问题,如何能够最快速地得到帮助?
A: 尽量详细描述自己使用的组件版本,重现步骤,最好是能够附上一个 demo,方便他人定位你的问题。我们推荐使用 codePen,http://codepen.io/eternalsky/pen/WpzYrv/
Q: 我的应用打包之后 js 体积好大,如何优化?
A: 首先请确保组件是按照按需加载的方式引用,详情请查看开始使用文档。其次,请检查自己的应用中是否有引用,但未真正使用的组件或者类库。最后,你可以尝试一下使用 code spliting,nowa 工具中集成了 require.ensure 的使用方法。
Q: 我有钉钉 nativeAPI 的使用或者和钉钉容器层相关的问题?
A: 请在钉钉上搜索群号“11768602”,加入“钉钉开发者交流群”咨询。
Q: 我有 nattyFetch 使用相关的问题?
A: 请扫描下方二维码,加入 nattyFetch 答疑群。
Q: 我有 Refast 使用相关的问题?
A: 可以在这里找到帮助:http://doc.refast.cn/
Q: 询问和钉钉 E 应用相关的问题?
Q: 报错:Uncaught Error: Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.
A: 这是 React min 版的提示,去掉 react.min.js
或者 react-with-addons.min.js
中的 min 才能看到真正的 React 报错。
Q: 报错:Uncaught Error: Invariant Violation: Element type is invalid: expected a string (for built-in components) or a class/function but got: xxx
A: 这通常是因为你的代码中引用了一个组件是没有的或者没有获取到,在控制台中打出来看下就明白了。
Q: 报错:Uncaught Error: this.isMounted is not a function
A: 这是 React 0.14.0 的 bug,请更换版本至 0.14.2 以上。
3.3.1(最新)
https://salt-ui.github.io/components/slot
初始化时,设定默认选中值,弹出选择框,点击完成,并没有得到临时值
在官方Demo,弹出下拉框之前设置默认选中Value,如下代码
showSlot() { this.setState({value:[{ text:2004, value:2004 }]}); this.refs.slot.show(); }
弹出效果如图
点击完成没有得到2004,而是得到2000
请按照以下模板填写
3.1.18
官网的layer版本显示的1.1.0,但是nowa saltui脚手架的版本已经是1.1.12了,里面layer组件的字段相差很大。
请按照以下模板填写
希望可以把这个组件的图片引入方式支持 base64 的图片地址,不然用起来很麻烦,支持 base64 的图片地址以后我们开发会很方便,希望尽早的支持。
请按照以下模板填写
3.1.17
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.