Skip to content

Commit

Permalink
Fix issues that caused build to fail
Browse files Browse the repository at this point in the history
  • Loading branch information
shadowbas authored and bas080 committed Jan 14, 2025
1 parent ef2bdea commit d5e0119
Show file tree
Hide file tree
Showing 10 changed files with 5,734 additions and 844 deletions.
47 changes: 20 additions & 27 deletions src/app/accessible-table/accessible-table.component.ts
Original file line number Diff line number Diff line change
@@ -1,18 +1,34 @@
// --------- BEGIN RUNBOX LICENSE ---------
// Copyright (C) 2016-2025 Runbox Solutions AS (runbox.com).
//
// This file is part of Runbox 7.
//
// Runbox 7 is free software: You can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the
// Free Software Foundation, either version 3 of the License, or (at your
// option) any later version.
//
// Runbox 7 is distributed in the hope that it will be useful, but
// WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Runbox 7. If not, see <https://www.gnu.org/licenses/>.
// ---------- END RUNBOX LICENSE ----------

import {
OnDestroy,
AfterViewChecked,
ChangeDetectionStrategy,
AfterViewInit,
Component,
ContentChild,
ContentChildren,
ElementRef,
EventEmitter,
HostListener,
Input,
OnChanges,
Output,
QueryList,
SimpleChanges,
TemplateRef,
ViewChild,
Expand All @@ -23,29 +39,6 @@ import { ScrollingModule, CdkVirtualScrollViewport } from '@angular/cdk/scrollin
import { ListRange } from '@angular/cdk/collections';
import { BehaviorSubject, Subscription } from 'rxjs';

// function withResize() {
//
// // Detect on double click if the cursor is the resize one. This is how I know if the user wants to make the column auto or jump to shortest value.
// // var cursor = e.target.style.cursor;
//
// // 1. First let the table be rendered and do nothing. (unless absolute values have already been assigned).
// // 2. On click we assign the absolute values to all columns and start resizing the current one. (Prevents other columns from moving during resize).
// // 3. On resize done we remove the absolute values of all columns that have not been given an explicit width.
// // 4. We store the latest configured value in the preferences service.
//
// // - dblclick event remove the absolute value. It checks if the style.cursor is the resize one.
//
// }


// TODO: Consider use selection model in order to deal with reference issues. Either in here or app.component
// https://github.com/angular/components/blob/main/src/cdk/collections/selection-model.ts#L237
// - Seriously consider placing the checkboxes outside of this component and in the app.component.
// - This would make the app.component responsible for selection state which would make this component more dumb
// The beneift of that is that we don't need to pass it equality checkers and such.
// - Think about what to do with clicks on the row with shift and ctrl.
// - Think about how to share whether a row is selected or not. (for styling).
// - Changing the templating API might give more freedom to style.
@Component({
selector: 'app-accessible-table',
standalone: true, // Make the component standalone
Expand All @@ -65,7 +58,7 @@ export class AccessibleTableComponent implements OnDestroy, AfterViewChecked, Af

@Input() scrollToIndex: null | number = null

private firstRowHeight = new BehaviorSubject<number>(100);
firstRowHeight = new BehaviorSubject<number>(100);

private renderedRangeSub!: Subscription;

Expand Down
2 changes: 0 additions & 2 deletions src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,6 @@ import { FilterSelectionModel } from './models/filter-selection-model';
import { BindableSelectionModel } from './models/bindable-selection-model';
import { Direction } from './sort-button/sort-button.component';

const fetchedSymbol = Symbol('fetched')

const LOCAL_STORAGE_SETTING_MAILVIEWER_ON_RIGHT_SIDE_IF_MOBILE = 'mailViewerOnRightSideIfMobile';
const LOCAL_STORAGE_SETTING_MAILVIEWER_ON_RIGHT_SIDE = 'mailViewerOnRightSide';
const LOCAL_STORAGE_VIEWMODE = 'rmm7mailViewerViewMode';
Expand Down
Loading

0 comments on commit d5e0119

Please sign in to comment.