Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jun 18 2019 18:50
    @StephenFluin banned @piotr-mamenas
Zurie
@zurie
thats my opinion on how i;d manage it
SAGO
@SAGOlab
yes...I have three columns and every columns need to open thir drawer
Zurie
@zurie
ok so the draweres are inside each column
SAGO
@SAGOlab
yep
Zurie
@zurie
got it
SAGO
@SAGOlab
is possible?
Zurie
@zurie
yes
SAGO
@SAGOlab
how
Zurie
@zurie
not 100% sure but i do something like this for 1 sidenav, maybe it can be modified to work etc
import { Injectable } from '@angular/core';
import {MatDrawerToggleResult, MatSidenav} from '@angular/material/sidenav';

@Injectable()
export class SidenavService {
    private sidenav!: MatSidenav;


    public setSidenav(sidenav: MatSidenav): void {
        this.sidenav = sidenav;
    }

    public open(): Promise<MatDrawerToggleResult> {
        return this.sidenav.open();
    }


    public close(): Promise<MatDrawerToggleResult> {
        return this.sidenav.close();
    }

    public toggle(): void {
        this.sidenav.toggle();
    }
}
        <mat-sidenav #sidenav>
            // etc
        </mat-sidenav>
<div id="menu" (click)="submenuVisible = false;sidenav.toggle()">
    @ViewChild('sidenav') public sidenav!: MatSidenav;
sorry i am not able to help more
SAGO
@SAGOlab
ok thanks
Zurie
@zurie
one is a service. sidenav in your app.component.html for example. and then view child would be in the app.component.ts which may not be relative but it would be some-thing like that just subsitute your files and locations
also in your constructor bind up the service etc
    constructor(
        private sidenavService: SidenavService,
    )
ngAfterViewInit(): void {
        this.sidenavService.setSidenav(this.sidenav);
its like a indiana jones serect tomb puzzle
:D
SAGO
@SAGOlab
thanks
meanstackBasit
@meanstackBasit
hello @danww hope you are fine! I am using mat input chip with auto complete in reactive form using angular submit form is working fine for me! A issue I am facing here when I update form the problem is that how to retrieve mat chips as I use to create a post I AM ONLY GETTING VALUE OF CHIPS IN FORM this is a problem
Daniel Willis
@danww
Hi @meanstackBasit, I am well thanks. Are you able to provide a Stackblitz example of your issue?
Andrew Collier
@acollier88
If I want to make a PR to solve this issue:
angular/components#10270
introduced by:
angular/components#8251
on an older version of angular 8.2.x. Is this supported or is the protocol only to submit PRs for the latest branch?
SAGO
@SAGOlab

Hi there, I have a mat-selection-list

 <mat-selection-list #priority (selectionChange)="isChecked($event, priority.selectedOptions.selected)">
      <mat-list-option *ngFor="let label of priorityLabels;let i = index" checkboxPosition="before" (click)="stopPropagation($event);" [value]="label">
        {{ label }}
      </mat-list-option>
    </mat-selection-list>

How can I get the non selected items?

I need to create a filter that do something only if, for example, the first and the last are selected, or the first and the third and so on....

or if one is checked the others are disabled?
SAGO
@SAGOlab
no one?
Sanket Thotange
@iamsank8
@SAGOlab - You will need to write your own functionality using ngModel from mat-selection-list.
SAGO
@SAGOlab
uhm ok...have you some example?
Sanket Thotange
@iamsank8
what exactly do you need as a result? the index or the option values which are not selected?
SAGO
@SAGOlab
@iamsank8 both, my goal is to sum the results returned from the checkbox selected, so if I check the first checkbox and the last (for example), I want to display a new array with both object that comes from the single checkbox, so I need to check if multiple checkboxes are checked and which are this checkbox
Sanket Thotange
@iamsank8
<mat-selection-list #priority (selectionChange)="isChecked($event, priority.selectedOptions.selected)" [(ngModel)]="listSelection"> <mat-list-option *ngFor="let label of priorityLabels;let i = index" checkboxPosition="before" (click)="stopPropagation($event);" [value]="label"> {{ label }} </mat-list-option> </mat-selection-list>
Now in you code
let notSelectedList = this.priorityLabels.filter(pl=> !this.listSelection.includes(pl)); let selectedList = this.priorityLabels.filter(pl=> this.listSelection.includes(pl));
SAGO
@SAGOlab
thanks, but what is listSelection?
Sanket Thotange
@iamsank8
[(ngModel)]="listSelection"
This should contain all the values which are checked.
SAGO
@SAGOlab
ok, but list selection in typescript what is? something like listSelection: any
?
SAGO
@SAGOlab
@iamsank8 thanks a lot sir
Sanket Thotange
@iamsank8
Welcome
BuZZ-dEE
@buzz-dee:matrix.org
[m]
hello, i saw there is a new release which should fix angular/components#17923 and i think also this one angular/components#18695 , but it seems for me, that it is not really fixed, because scolling an dragging is not really well working. Also this had already worked well in chrome, but it is also broken in chrome now
kannan Ganesan
@kannangan
hii team,
I want to implement A chip input is a form control that can be used to select and remove multiple items from a list using control value accesor.(herefore it must implement the ControlValueAccessor).. can some one tell me how to do this.. or provide me with a link of example code
Like stackblitz
redoc-n
@redoc123
Can't bind to 'ngIf' since it isn't a known property of 'form'. --- can anyone assist with this?
SAGO
@SAGOlab
Hi there there is a way to have MatAutocompletePanel always visible
?
kelly
@kellyprankin
Anyone know a cleaner way to do Angular Material Tables without leaking the DataSource into a component? I'd rather just inject a service and async pipe subscribe
While still being able to do pagination etc
1 reply