angular / components

Component infrastructure and Material Design components for Angular
https://material.angular.io
MIT License
24.35k stars 6.74k forks source link

Missing docs for properties/methods #8832

Open rafaelss95 opened 6 years ago

rafaelss95 commented 6 years ago

Bug, feature request, or proposal:

Bug/Proposal.

What is the expected behavior?

The listed propeties/methods have no docs.

What is the current behavior?

Here's the list that I found of all missing docs.

Class Properties Methods
MatAutocompleteTrigger autocomplete, panelOpen
MatChip ariaSelected
MatChipInput focused focus
MatChipList controlType , ngControl, role onContainerClick, setDescribedByIds
MatDialogClose dialogRef
MatDialogRef id
MatDialogTitle id
MatDatepickerInput registerOnValidatorChange, validate
MatExpansionPanelHeader panel
MatError id
MatInput empty, ngControl, shouldLabelFloat focus, onContainerClick, setDescribedByIds
MatListOption selectionList
MatSelect ngControl, shouldLabelFloat
MatSlideToggleChange All MatSlideToggleChange properties
SimpleSnackBar snackBarRef

Is there anything else we should know?

Related to #8789.

rafaelss95 commented 6 years ago

I noticed that some properties/methods are inherited from a parent class. Is there a way to get the docs copied from there instead of maintain two EQUAL docs?

CDDelta commented 6 years ago

Good news PR #9299 is fixing this.

rafaelss95 commented 6 years ago

AFAIK that PR is only related for some missing docs, not all.

devversion commented 6 years ago

Every member that is inherited is now showing up in the docs. If you still see some members that are not showing up properly, please file a new issue/or respond here and cc. me. Thanks!

rafaelss95 commented 6 years ago

@DevVersion I guess you solved part of the "problem". This issue doesn't consists only about inherited members. There are a few members (in table that I listed) that are still undocumented and aren't inherited from anywhere.

It'd be great if you reopen this issue.


By the way, do you mind if I send separate PRs to fix some of them?

devversion commented 6 years ago

@rafaelss95 That might be true. I didn't specifically look at all members in the table you posted, because I thought it was also about the inherited members.

And sure, please go ahead and submit a PR. For such small changes It would be better to just have one PR for all members.

rcanacci commented 6 years ago

Does anyone here know how to use 'shouldLabelFloat' on a MatInput?

Completely lost, docs are useless.

rafaelss95 commented 6 years ago

@DevVersion:

ExpansionPanel:

expanded is declared like this:

https://github.com/angular/material2/blob/7024dc49f8cc067da14be36a8172437e03074186/src/lib/expansion/expansion-panel.ts#L75

Is there a specific reason to it be declared this way, instead of the usual @Input()? I'm asking because this way, AFAIK, it can't be documented.

Sort:

matSortDisabled is declared like this:

https://github.com/angular/material2/blob/7024dc49f8cc067da14be36a8172437e03074186/src/lib/sort/sort.ts#L58

...however it appears as disabled in docs.


Also, all the inputs declared in Component/Directive metadata appear without @Input() decorated. Is it the expected behavior?

benedikt-roth commented 6 years ago

How can one hide the updateErrorState from the docs? (For example in MatSelect.) From what I understand this should not be part of the public API.

jelbourn commented 3 years ago

Closing this since, as far as I can tell, all of these APIs are now correctly captured in the generated API docs.

rafaelss95 commented 3 years ago

@jelbourn I still see some of them undocumented or wrongly documented (see MatDatepickerInput#registerOnValidatorChange - it appears in docs, while it shouldn't, as it's marked with @docs-private annotation. Also, I think @docs-private shouldn't even be necessary, if that method was listed here: https://github.com/angular/components/blob/ad248652e7da31398176fe11878b59805e440b5a/tools/dgeni/common/private-docs.ts#L4-L19).

Should I create a new issue or just update this issue with the still missing members (and it will be reopened)?

rafaelss95 commented 3 years ago

Btw, here is the updated list:

Class Properties Methods
MatAutocompleteTrigger optionGroups, options
MatButtonToggleDefaultOptions appearance
MatCheckboxDefaultOptions clickAction, color
MatChipList errorState , stateChanges updateErrorState
MatDialogRef id
MatDialogClose id
MatDialogTitle id
MatDialogRef id
MatDatepickerInput registerOnValidatorChange, validate
MatStartDate errorStateMatcher, errorState, stateChanges registerOnValidatorChange, validate
MatEndDate errorStateMatcher, errorState, stateChanges registerOnValidatorChange, validate
MatCalendarHeader calendar, periodButtonLabel
MatCalendarUserEvent event, value
MatExpansionPanelHeader panel
MatError id
MatFormFieldDefaultOptions appearance, hideRequiredMarker
MatInput errorState updateErrorState
MatTextareaAutosize matAutosize, matAutosizeMaxRows, matAutosizeMinRows, placeholder`
~MatListOption~ ~selectionList~
MatSelect customTrigger, errorState, ngControl, optionGroups, options, stateChanges open, updateErrorState
MatSlideToggleChange defaults
SimpleSnackBar snackBarRef
TextOnlySnackBar action, data, hasActon, snackBarRef
MatMenu panelId
ProgressAnimationEnd value
SafeResourceUrlWithIconOptions options, url
MatRadioDefaultOptions color
MatHorizontalStepper animationDone, color, disableRipple, labelPosition, steps
MatVerticalStepper animationDone, color, disableRipple, labelPosition, steps
MatStepperIcon templateRef
MatTableDataSourcePageEvent length, pageIndex, pageSize
MatTableDataSourcePaginator initialized, length, page, pageIndex, pageSize
MatTabLabel origin
MatTooltipDefaultOptions hideDelay, position, showDelay, touchGestures, touchendHideDelay
MatTreeNode isExpanded, level
MatTreeNodeDef data, template
MatNestedTreeNode node, isExpanded, level
MatTreeNodeToggle recursive
MatTreeNodeOutlet viewContainer
MatTreeFlattener getChildren, getLevel, isExpandable, transformFunction
MatTreeFlatDataSource data connect, disconnect
MatTreeNestedDataSource connect, disconnect
CdkDragHandle element
CdkDragPreview templateRef
CdkDragPlaceholder templateRef
DragDropConfig boundaryElement, constrainPosition, dragStartDelay, draggingDisabled, listAutoScrollDisabled, listOrientation, lockAxis, previewClass, previewContainer, rootElementSelector, sortingDisabled, zIndex
OverlaySizeConfig height, maxHeight, maxWidth, minHeight, minWidth, width
ConnectedPosition offsetX, offsetY, originX, originY, overlayX, overlayY, panelClass, weight
OriginConnectionPosition originX, originY
OverlayConnectionPosition overlayX, overlayY
CdkPortal origin detach
TemplatePortalDirective origin detach
BasePortalOutlet attachDomPortal
BasePortalHost attachDomPortal
CdkScrollable dir, elementRef, ngZone, scrollDispatcher
CdkVirtualScrollViewport elementRef
ViewportScrollPosition left, top
CdkVirtualScrollRepeater dataStream
CdkNoDataRow templateRef
RowOutlet viewContainer
CellDef template
StickyUpdate elements, offsets, sizes
ComponentHarness locatorFactory
CdkTextareaAutosize placeholder
CdkNestedTreeNode isExpanded, level
CdkTreeNodeDef template
CdkTreeNodeOutlet viewContainer
CdkTreeNode isExpanded, level
FlatTreeControl getLevel, isExpandable, options
NestedTreeControl getChildren, options
FlatTreeControlOptions trackBy
NestedTreeControlOptions trackBy