Skip to content

Commit

Permalink
Merge branch 'main' into fix-file-upload-btn
Browse files Browse the repository at this point in the history
  • Loading branch information
Mnickii authored Jul 12, 2023
2 parents ec5e666 + 764bf12 commit 1a3ac7e
Show file tree
Hide file tree
Showing 18 changed files with 6,811 additions and 9,881 deletions.
2,491 changes: 0 additions & 2,491 deletions .github/fabricbot.json

This file was deleted.

266 changes: 266 additions & 0 deletions .github/policies/resourceManagement.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,266 @@
id:
name: GitOps.PullRequestIssueManagement
description: GitOps.PullRequestIssueManagement primitive
owner:
resource: repository
disabled: false
where:
configuration:
resourceManagementConfiguration:
scheduledSearches:
- description:
frequencies:
- hourly:
hour: 1
filters:
- isIssue
- isOpen
- hasLabel:
label: 'Needs: Author Feedback'
- hasLabel:
label: no-recent-activity
- noActivitySince:
days: 3
actions:
- closeIssue
- description:
frequencies:
- hourly:
hour: 1
filters:
- isIssue
- isOpen
- hasLabel:
label: 'Needs: Author Feedback'
- noActivitySince:
days: 4
- isNotLabeledWith:
label: no-recent-activity
actions:
- addLabel:
label: no-recent-activity
- addReply:
reply: This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for **4 days**. It will be closed if no further activity occurs **within 3 days of this comment**.
- description:
frequencies:
- hourly:
hour: 1
filters:
- isIssue
- isOpen
- hasLabel:
label: duplicate
- noActivitySince:
days: 1
actions:
- addReply:
reply: This issue has been marked as duplicate and has not had any activity for **1 day**. It will be closed for housekeeping purposes.
- closeIssue
- description:
frequencies:
- hourly:
hour: 6
filters:
- isPullRequest
- isOpen
- hasLabel:
label: 'Needs: Author Feedback'
- hasLabel:
label: no-recent-activity
- noActivitySince:
days: 7
actions:
- closeIssue
- description:
frequencies:
- hourly:
hour: 6
filters:
- isPullRequest
- isOpen
- hasLabel:
label: 'Needs: Author Feedback'
- noActivitySince:
days: 7
- isNotLabeledWith:
label: no-recent-activity
actions:
- addLabel:
label: no-recent-activity
- addReply:
reply: This pull request has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for **7 days**. It will be closed if no further activity occurs **within 7 days of this comment**.
eventResponderTasks:
- if:
- payloadType: Issue_Comment
- isAction:
action: Created
- isActivitySender:
issueAuthor: True
- hasLabel:
label: 'Needs: Author Feedback'
then:
- addLabel:
label: 'Needs: Attention :wave:'
- removeLabel:
label: 'Needs: Author Feedback'
description:
- if:
- payloadType: Issues
- not:
isAction:
action: Closed
- hasLabel:
label: no-recent-activity
then:
- removeLabel:
label: no-recent-activity
description:
- if:
- payloadType: Issue_Comment
- hasLabel:
label: no-recent-activity
then:
- removeLabel:
label: no-recent-activity
description:
- if:
- payloadType: Pull_Request
then:
- inPrLabel:
label: 'State: In Review'
description:
- if:
- payloadType: Issue_Comment
then:
- cleanEmailReply
description:
- if:
- payloadType: Pull_Request_Review
- isAction:
action: Submitted
- isReviewState:
reviewState: Changes_requested
then:
- addLabel:
label: 'Needs: Author Feedback'
description:
- if:
- payloadType: Pull_Request
- isActivitySender:
issueAuthor: True
- not:
isAction:
action: Closed
- hasLabel:
label: 'Needs: Author Feedback'
then:
- removeLabel:
label: 'Needs: Author Feedback'
description:
- if:
- payloadType: Issue_Comment
- isActivitySender:
issueAuthor: True
- hasLabel:
label: 'Needs: Author Feedback'
then:
- removeLabel:
label: 'Needs: Author Feedback'
description:
- if:
- payloadType: Pull_Request_Review
- isActivitySender:
issueAuthor: True
- hasLabel:
label: 'Needs: Author Feedback'
then:
- removeLabel:
label: 'Needs: Author Feedback'
description:
- if:
- payloadType: Pull_Request
- not:
isAction:
action: Closed
- hasLabel:
label: no-recent-activity
then:
- removeLabel:
label: no-recent-activity
description:
- if:
- payloadType: Issue_Comment
- hasLabel:
label: no-recent-activity
then:
- removeLabel:
label: no-recent-activity
description:
- if:
- payloadType: Pull_Request_Review
- hasLabel:
label: no-recent-activity
then:
- removeLabel:
label: no-recent-activity
description:
- if:
- payloadType: Pull_Request
- hasLabel:
label: Auto Merge
then:
- enableAutoMerge:
mergeMethod: Squash
description:
- if:
- payloadType: Pull_Request
- labelRemoved:
label: Auto Merge
then:
- disableAutoMerge
description:
- if:
- payloadType: Issues
then: []
description:
- if:
- payloadType: Issues
then: []
description:
- if:
- payloadType: Issues
then: []
description:
- if:
- payloadType: Issues
then: []
description:
- if:
- payloadType: Issues
then: []
description:
- if:
- payloadType: Pull_Request
- isAction:
action: Opened
then:
- addReply:
reply: >-
Thank you for creating a Pull Request @${issueAuthor}.
This is a checklist for the PR reviewer(s) to complete before approving and merging this PR:
- [ ] I have verified a documentation PR has been linked and is approved (or not applicable)
- [ ] I have ran this PR locally and have tested the fix/feature
- [ ] I have verified that stories have been added to storybook (or not applicable)
- [ ] I have tested existing stories in storybook to verify no regression has occured
- [ ] I have tested the solution in at least two browsers (Edge + 1 non-Chromium based browser)
description:
onFailure:
onSuccess:
7 changes: 7 additions & 0 deletions .storybook/manager-head.html
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,13 @@
color: #616159 !important;
}

/* Fix color contrast of left expanded/collapsed chevrons */

.sto-bt79wf,
.sto-1j9r8vi {
color: unset;
}

/* Removes Find component feature */
.css-8ktt77 {
display: none;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ registerFluentComponents(fluentProgressRing);

@customElement('file-list')
export class MgtFileList extends MgtTemplatedComponent implements CardSection {
private _isCompact = false;
@state() private _isCompact = false;
/**
* Array of styles to apply to the element. The styles should be defined
* using the `css` tag function.
Expand Down Expand Up @@ -554,7 +554,6 @@ export class MgtFileList extends MgtTemplatedComponent implements CardSection {
*/
protected clearState(): void {
super.clearState();
this._isCompact = false;
this.files = null;
}

Expand All @@ -566,7 +565,6 @@ export class MgtFileList extends MgtTemplatedComponent implements CardSection {
*/
public asCompactView() {
this._isCompact = true;
this.requestUpdate();
return this;
}

Expand All @@ -578,7 +576,6 @@ export class MgtFileList extends MgtTemplatedComponent implements CardSection {
*/
public asFullView() {
this._isCompact = false;
this.requestUpdate();
return this;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ $signed-out-bg: padding-box linear-gradient(var(--neutral-fill-rest), var(--neut
$signed-out-background: #{var(--login-signed-out-button-background, $signed-out-bg)};
$signed-out-hover-background: #{var(--login-signed-out-button-hover-background, var(--neutral-fill-stealth-hover))};
$login-popup-background-color: #{var(--login-popup-background-color, var(--neutral-layer-1))};
$login-account-item-hover-bg-color: #{var(--login-account-item-hover-bg-color, var(--neutral-fill-stealth-hover))};
$button-padding: var(--login-button-padding, 0);
$login-flyout-command-text-color: #{var(--login-flyout-command-text-color, var(--accent-foreground-rest))};

:host {
.signed-in-person {
Expand Down Expand Up @@ -108,13 +110,15 @@ $button-padding: var(--login-button-padding, 0);
list-style-type: none;

&:hover {
background: var(--neutral-fill-stealth-hover);
background: $login-account-item-hover-bg-color;

--person-background-color: $login-account-item-hover-bg-color;
}
}

.flyout {
.flyout-command {
color: var(--accent-foreground-rest);
color: $login-flyout-command-text-color;
}

.popup {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ type PersonViewConfig = {
* @cssprop --login-signed-out-button-text-color - {Color} the background color of the component when signed out.
* @cssprop --login-button-padding - {Length} the padding of the button. Default is 0px.
* @cssprop --login-popup-background-color - {Color} the background color of the popup.
* @cssprop --login-popup-text-color - {Color} the color of the text in the popup.
* @cssprop --login-popup-command-button-background-color - {Color} the color of the background to the popup command button.
* @cssprop --login-popup-padding - {Length} the padding applied to the popup card. Default is 16px.
* @cssprop --login-add-account-button-text-color - {Color} the color for the text and icon of the add account button.
Expand All @@ -80,6 +79,8 @@ type PersonViewConfig = {
* @cssprop --login-command-button-text-color - {Color} the color for the text of the command button.
* @cssprop --login-command-button-background-color - {Color} the color for the background of the command button.
* @cssprop --login-command-button-hover-background-color - {Color} the color for the background of the command button on hovering.
* @cssprop --login-account-item-hover-bg-color - {Color} the background color of the account item on hover.
* @cssprop --login-flyout-command-text-color - {Color} the color for the text of the flyout command button.
*/
@customElement('login')
export class MgtLogin extends MgtTemplatedComponent {
Expand Down
1 change: 1 addition & 0 deletions packages/mgt-element/src/Graph.ts
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ export const createFromProvider = (provider: IProvider, version?: string, compon
const baseURL = provider.baseURL ? provider.baseURL : MICROSOFT_GRAPH_DEFAULT_ENDPOINT;
const client = Client.initWithMiddleware({
middleware: chainMiddleware(...middleware),
customHosts: typeof provider.customHosts === undefined ? null : new Set(provider.customHosts),
baseUrl: baseURL
});

Expand Down
12 changes: 12 additions & 0 deletions packages/mgt-element/src/components/baseProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,18 @@ export abstract class MgtBaseProvider extends MgtBaseComponent {
})
public baseUrl: GraphEndpoint;

/**
* Custom Hosts to be passed through to the graph client
*
* @memberof MgtBaseProvider
*/
@property({
attribute: 'custom-hosts',
type: String,
converter: newValue => newValue.split(',').map(s => s.trim())
})
public customHosts?: string[];

private _provider: IProvider;

/**
Expand Down
Loading

0 comments on commit 1a3ac7e

Please sign in to comment.