Misc mobile fixes
parent
190e273bc5
commit
3798645e93
|
@ -612,10 +612,8 @@ export default class Timeline extends Mixins(GlobalMixin, UserConfig) {
|
||||||
// Special headers
|
// Special headers
|
||||||
if (head.dayId === this.TagDayID.FOLDERS) {
|
if (head.dayId === this.TagDayID.FOLDERS) {
|
||||||
return (head.name = this.t("memories", "Folders"));
|
return (head.name = this.t("memories", "Folders"));
|
||||||
} else if (head.dayId === this.TagDayID.TAGS) {
|
} else if (head.dayId === this.TagDayID.TAGS || head.dayId === this.TagDayID.FACES) {
|
||||||
return (head.name = this.t("memories", "Tags"));
|
return (head.name = "");
|
||||||
} else if (head.dayId === this.TagDayID.FACES) {
|
|
||||||
return (head.name = this.t("memories", "People"));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Make date string
|
// Make date string
|
||||||
|
@ -692,10 +690,17 @@ export default class Timeline extends Mixins(GlobalMixin, UserConfig) {
|
||||||
delete day.detail;
|
delete day.detail;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Special headers that we should be tiny
|
||||||
|
let headerSize = 40;
|
||||||
|
if (day.dayid === this.TagDayID.TAGS ||
|
||||||
|
day.dayid === this.TagDayID.FACES) {
|
||||||
|
headerSize = 10;
|
||||||
|
}
|
||||||
|
|
||||||
// Add header to list
|
// Add header to list
|
||||||
const head: IHeadRow = {
|
const head: IHeadRow = {
|
||||||
id: ++this.numRows,
|
id: ++this.numRows,
|
||||||
size: 40,
|
size: headerSize,
|
||||||
type: IRowType.HEAD,
|
type: IRowType.HEAD,
|
||||||
selected: false,
|
selected: false,
|
||||||
dayId: day.dayid,
|
dayId: day.dayid,
|
||||||
|
@ -1448,7 +1453,8 @@ export default class Timeline extends Mixins(GlobalMixin, UserConfig) {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
> .name {
|
> .name {
|
||||||
transition: margin 0.2s ease;
|
display: block;
|
||||||
|
transition: transform 0.2s ease;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1458,12 +1464,14 @@ export default class Timeline extends Mixins(GlobalMixin, UserConfig) {
|
||||||
opacity: 0.7;
|
opacity: 0.7;
|
||||||
}
|
}
|
||||||
> .name {
|
> .name {
|
||||||
margin-left: 25px;
|
transform: translateX(25px);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
&.selected > .select {
|
&.selected > .select {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@include phone { transform: translateX(8px); }
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Timeline */
|
/** Timeline */
|
||||||
|
|
|
@ -17,8 +17,8 @@ export function getShortDateStr(date: Date) {
|
||||||
/** Get long date string with optional year if same as current */
|
/** Get long date string with optional year if same as current */
|
||||||
export function getLongDateStr(date: Date, skipYear=false, time=false) {
|
export function getLongDateStr(date: Date, skipYear=false, time=false) {
|
||||||
return date.toLocaleDateString(getCanonicalLocale(), {
|
return date.toLocaleDateString(getCanonicalLocale(), {
|
||||||
weekday: 'long',
|
weekday: 'short',
|
||||||
month: 'long',
|
month: 'short',
|
||||||
day: 'numeric',
|
day: 'numeric',
|
||||||
year: (skipYear && date.getUTCFullYear() === new Date().getUTCFullYear()) ? undefined : 'numeric',
|
year: (skipYear && date.getUTCFullYear() === new Date().getUTCFullYear()) ? undefined : 'numeric',
|
||||||
timeZone: 'UTC',
|
timeZone: 'UTC',
|
||||||
|
|
Loading…
Reference in New Issue