"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "packages/daygrid/src/TableCellTop.tsx" between
fullcalendar-5.9.0.tar.gz and fullcalendar-5.10.0.tar.gz

About: FullCalendar is a full-sized drag & drop JavaScript event calendar.

TableCellTop.tsx  (fullcalendar-5.9.0):TableCellTop.tsx  (fullcalendar-5.10.0)
import { import {
createElement, createElement,
DateMarker, DateMarker,
DateRange, DateRange,
buildNavLinkData,
DayCellContentArg, DayCellContentArg,
DayCellContent, DayCellContent,
BaseComponent, BaseComponent,
DateProfile, DateProfile,
Dictionary, Dictionary,
Fragment, Fragment,
buildNavLinkAttrs,
} from '@fullcalendar/common' } from '@fullcalendar/common'
interface TableCellTopProps { interface TableCellTopProps {
date: DateMarker date: DateMarker
dateProfile: DateProfile dateProfile: DateProfile
showDayNumber: boolean showDayNumber: boolean
dayNumberId: string
forceDayTop: boolean // hack to force-create an element with height (created b y a nbsp) forceDayTop: boolean // hack to force-create an element with height (created b y a nbsp)
todayRange: DateRange todayRange: DateRange
extraHookProps?: Dictionary extraHookProps?: Dictionary
} }
export class TableCellTop extends BaseComponent<TableCellTopProps> { export class TableCellTop extends BaseComponent<TableCellTopProps> {
render() { render() {
let { props } = this let { props } = this
let navLinkAttrs = buildNavLinkAttrs(this.context, props.date)
let navLinkAttrs = this.context.options.navLinks
? { 'data-navlink': buildNavLinkData(props.date), tabIndex: 0 }
: {}
return ( return (
<DayCellContent <DayCellContent
date={props.date} date={props.date}
dateProfile={props.dateProfile} dateProfile={props.dateProfile}
todayRange={props.todayRange} todayRange={props.todayRange}
showDayNumber={props.showDayNumber} showDayNumber={props.showDayNumber}
extraHookProps={props.extraHookProps} extraHookProps={props.extraHookProps}
defaultContent={renderTopInner} defaultContent={renderTopInner}
> >
{(innerElRef, innerContent) => ( {(innerElRef, innerContent) => (
(innerContent || props.forceDayTop) && ( (innerContent || props.forceDayTop) && (
<div className="fc-daygrid-day-top" ref={innerElRef}> <div className="fc-daygrid-day-top" ref={innerElRef}>
<a className="fc-daygrid-day-number" {...navLinkAttrs}> <a
id={props.dayNumberId}
className="fc-daygrid-day-number"
{...navLinkAttrs}
>
{innerContent || <Fragment>&nbsp;</Fragment>} {innerContent || <Fragment>&nbsp;</Fragment>}
</a> </a>
</div> </div>
) )
)} )}
</DayCellContent> </DayCellContent>
) )
} }
} }
 End of changes. 5 change blocks. 
6 lines changed or deleted 8 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)