Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
react-mobile-calendar
Advanced tools
Readme
npm i react-mobile-calendar
import React from 'react'
import ReactDOM from 'react-dom'
import MultiMonthView,{DatePicker} from 'react-mobile-calendar'
const days = [
{
key:20161201,
text:'¥ 3000'
},
{
key:20161202,
text:'¥ 1000'
},
{
key:20161203,
text:'¥ 1000'
},
];
const onDayClick = (day,rangeDays,is_complete)=>{
for (var value of rangeDays) {
if(value.disable==false) { //使用rendDay 自定义的数据
console.log(value.moment.format('YYYY-MM-DD')+'不可以订');
return false;
}
}
if(is_complete){
console.log('选择完毕');
}else{
console.log('选择退房时间')
}
return true;
};
const rendDay = (day,props)=>{
let day_my = days.find((value)=>(value.key==day.number));
if(day_my==undefined){
day.disable = false; //自定义数据
day.money = '暂无'; //自定义数据
}else{
day.money = day_my.text;
day.disable = true;
}
//自定义 一天的样式
props.children = <div className="day"><span className="textNum">{day.text}</span><span className="textMoney">{day.money}</span></div>;
};
ReactDOM.render(
<div>
<MultiMonthView startText="入住" endText="退房" monthNumber="5" viewMoment="2016-12" onDayClick={onDayClick} rendDay={rendDay}/>
</div>,
document.getElementById('root')
);
FAQs
> 用react做的用于手机端显示的日历
The npm package react-mobile-calendar receives a total of 0 weekly downloads. As such, react-mobile-calendar popularity was classified as not popular.
We found that react-mobile-calendar demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.