Changeset View
Changeset View
Standalone View
Standalone View
web/calendar/calendar.react.js
Show First 20 Lines • Show All 153 Lines • ▼ Show 20 Lines | ) { | ||||
} | } | ||||
if (columns.length === 7) { | if (columns.length === 7) { | ||||
rows.push(<tr key={week++}>{columns}</tr>); | rows.push(<tr key={week++}>{columns}</tr>); | ||||
columns = []; | columns = []; | ||||
} | } | ||||
} | } | ||||
let filterPanel = null; | let filterPanel = null; | ||||
let calendarContentStyle = null; | |||||
let filterButton = null; | let filterButton = null; | ||||
if (this.state.filterPanelOpen) { | if (this.state.filterPanelOpen) { | ||||
filterPanel = <FilterPanel toggleFilters={this.toggleFilters} />; | filterPanel = <FilterPanel toggleFilters={this.toggleFilters} />; | ||||
calendarContentStyle = { marginLeft: '300px' }; | |||||
} else { | } else { | ||||
filterButton = ( | filterButton = ( | ||||
<a className={css.filtersButton} onClick={this.toggleFilters}> | <a className={css.filtersButton} onClick={this.toggleFilters}> | ||||
<SWMansionIcon icon="filters-2" size={16} /> | <SWMansionIcon icon="filters-2" size={16} /> | ||||
</a> | </a> | ||||
); | ); | ||||
} | } | ||||
return ( | return ( | ||||
<div> | <div className={css.container}> | ||||
{filterPanel} | {filterPanel} | ||||
<div className={css.content} style={calendarContentStyle}> | <div className={css.content}> | ||||
<div> | <div> | ||||
{filterButton} | {filterButton} | ||||
<nav className={css.nav}> | <nav className={css.nav}> | ||||
<a | <a | ||||
className={css.monthLink} | className={css.monthLink} | ||||
href={prevURL} | href={prevURL} | ||||
onClick={this.onClickPrevURL} | onClick={this.onClickPrevURL} | ||||
> | > | ||||
▲ Show 20 Lines • Show All 98 Lines • Show Last 20 Lines |