Skip to content

Commit

Permalink
Merge branch 'dev' of https://github.com/rvdwegen/CIPP into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
rvdwegen committed Nov 14, 2023
2 parents 227206d + 0ca9ad2 commit 2fc4903
Show file tree
Hide file tree
Showing 34 changed files with 916 additions and 321 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/feature.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ body:
- Please search the existing feature request to see if there has been a similar issue filed.
- If a feature has been filed before, but not followed up by a contributor, you can develop the feature yourself by checking the development documentation [here](https://cipp.app/docs/dev/).
- If a feature has been filed before, but not followed up by a contributor, you can develop the feature yourself by checking the development documentation [here](https://docs.cipp.app/dev-documentation/cipp-dev-guide/setting-up-for-local-development).
- Repeat feature requests are allowed if the previous request has been closed for more than 30 days
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/Check_for_Version_Update.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
---
name: Check for Version Update
on: # yamllint disable-line rule:truthy
on:
pull_request:
branches: [master, main]
workflow_dispatch:
jobs:
build:
if: github.repository_owner == 'KelvinTegelaar'
name: 'Check for Version Update'
runs-on: ubuntu-latest
steps:
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/Close_Stale_Issues_and_PRs.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
---
name: 'Close stale issues and PRs'
on: # yamllint disable-line rule:truthy
on:
schedule:
- cron: '30 1 * * *'
jobs:
stale:
if: github.repository_owner == 'KelvinTegelaar'
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v4
with:
stale-issue-message: 'This issue is stale because it has been open 10 days with no activity. We will close this issue soon. If you want this feature implemented you can contribute it. See: https://cipp.app/GettingStarted/Contributions/ . Please notify the team if you are working on this yourself.'
stale-issue-message: 'This issue is stale because it has been open 10 days with no activity. We will close this issue soon. If you want this feature implemented you can contribute it. See: https://docs.cipp.app/dev-documentation/contributing-to-the-code . Please notify the team if you are working on this yourself.'
close-issue-message: 'This issue was closed because it has been stalled for 14 days with no activity.'
stale-issue-label: 'no-activity'
exempt-issue-labels: 'planned'
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/CodeQL_Analyser.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
---
name: 'CodeQL'
on: # yamllint disable-line rule:truthy
on:
pull_request:
branches: [master, main, dev, react]
schedule:
- cron: '26 17 * * 0'
jobs:
analyze:
if: github.repository_owner == 'KelvinTegelaar'
name: Analyze
runs-on: ubuntu-latest
permissions:
Expand Down
21 changes: 6 additions & 15 deletions .github/workflows/Comment_on_Issues.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
---
name: Add Comment
on: # yamllint disable-line rule:truthy
on:
issues:
types:
- labeled
jobs:
add-comment_bug:
if: github.event.label.name == 'unconfirmed-by-user'
if: github.repository_owner == 'KelvinTegelaar' && github.event.label.name == 'unconfirmed-by-user'
runs-on: ubuntu-latest
permissions:
issues: write
Expand All @@ -16,24 +16,15 @@ jobs:
with:
issue-number: ${{ github.event.issue.number }}
body: |
Thank you for creating a bug. Please make sure your bug is indeed a unique case by checking current and past issues, and reading the complete documentation at https://kelvintegelaar.github.io/CIPP
If your bug is a known documentation issue, it will be closed without notice by a contributor. To confirm that this is not a bug found in the documentation, please copy and paste the following comment: "I confirm that I have checked the documentation thoroughly and believe this to be an actual bug.".
Thank you for creating a bug. Please make sure your bug is indeed a unique case by checking current and past issues, and reading the complete documentation at https://docs.cipp.app/
If your bug is a known documentation issue, it will be closed without notice by a contributor. To confirm that this is not a bug found in the documentation, please copy and paste the following comment: "I confirm that I have checked the documentation thoroughly and believe this to be an actual bug."
Without confirming, your report will be closed in 24 hours. If you'd like this bug to be assigned to you, please comment "I would like to work on this please!".
add-comment_fr:
if: github.event.label.name == 'enhancement'
if: github.repository_owner == 'KelvinTegelaar' && github.event.label.name == 'enhancement'
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- name: Add Comment
uses: peter-evans/create-or-update-comment@a35cf36e5301d70b76f316e867e7788a55a31dae
with:
issue-number: ${{ github.event.issue.number }}
body: |
Thank you for creating a feature request!
Your current priority is set to "No Priority". No Priority Feature requests automatically get closed in two days if a contributor does not accept the FR.
If you are a sponsor you can request an upgrade of priority. To upgrade the priority type "I would like to upgrade the priority".
If you want this feature to be integrated you can always do this yourself by checking out our contributions guide at https://cipp.app/docs/dev/. Contributors to the CIPP project reserve the right to close feature requests at will.
If you'd like this feature request to be assigned to you, please comment "I would like to work on this please!".
uses: peter-evans/create-or-update
6 changes: 3 additions & 3 deletions .github/workflows/Label_Issues.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
---
name: Label Issues
on: # yamllint disable-line rule:truthy
on:
issues:
types:
- opened
jobs:
label_issues_bugs:
if: contains(github.event.issue.title,'Bug')
if: github.repository_owner == 'KelvinTegelaar' && contains(github.event.issue.title, 'Bug')
runs-on: ubuntu-latest
permissions:
issues: write
Expand All @@ -17,7 +17,7 @@ jobs:
add-labels: 'unconfirmed-by-user'
repo-token: ${{ secrets.GITHUB_TOKEN }}
label_issues_frs:
if: contains(github.event.issue.title,'Feature')
if: github.repository_owner == 'KelvinTegelaar' && contains(github.event.issue.title, 'Feature')
runs-on: ubuntu-latest
permissions:
issues: write
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/Node_Project_Check.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: NodeJS Project Check
on: # yamllint disable-line rule:truthy
on:
pull_request:
branches:
- main
Expand All @@ -10,6 +10,7 @@ concurrency:
cancel-in-progress: false
jobs:
install-build:
if: github.repository_owner == 'KelvinTegelaar'
name: NPM Install and Build
runs-on: ubuntu-latest
strategy:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/label_sponsor_requests.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
---
name: Label Issues
on: # yamllint disable-line rule:truthy
on:
issues:
types:
- opened
jobs:
label_issues_bugs:
if: contains(github.event.issue.title,'Bug')
if: github.repository_owner == 'KelvinTegelaar' && contains(github.event.issue.title, 'Bug')
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- name: Sponsor Labels
uses: JasonEtco/[email protected]
with:
label: 'Sponsor Request'
label: 'Sponsor Request'
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"test": "react-scripts test",
"test:cov": "npm test -- --coverage --watchAll=false",
"test:debug": "react-scripts --inspect-brk test --runInBand",
"start-swa": "swa start --swa-config-location .vscode http://127.0.0.1:3000 --api-location http://localhost:7071",
"start-swa": "swa start --swa-config-location .vscode http://127.0.0.1:3000 --api-location http://127.0.0.1:7071",
"prepare": "husky install"
},
"config": {
Expand Down
2 changes: 1 addition & 1 deletion public/version_latest.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
4.5.0
4.5.5
19 changes: 19 additions & 0 deletions src/_nav.js
Original file line number Diff line number Diff line change
Expand Up @@ -682,6 +682,25 @@ const _nav = [
},
],
},
{
component: CNavGroup,
name: 'Tools',
section: 'Tools',
to: '/email/tools',
icon: <FontAwesomeIcon icon={faToolbox} className="nav-icon" />,
items: [
{
component: CNavItem,
name: 'Mailbox Restore Wizard',
to: '/email/tools/mailbox-restore-wizard',
},
{
component: CNavItem,
name: 'Mailbox Restores',
to: '/email/tools/mailbox-restores',
},
],
},
{
component: CNavTitle,
name: 'Settings',
Expand Down
2 changes: 1 addition & 1 deletion src/components/forms/RFFComponents.js
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,7 @@ export const RFFSelectSearch = ({
isMulti={multi}
/>
)}
<RFFCFormFeedback meta={meta} />
{meta.error && meta.touched && <span className="text-danger">{meta.error}</span>}
</div>
)
}}
Expand Down
3 changes: 3 additions & 0 deletions src/components/tables/CellGenericFormat.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@ export const cellGenericFormatter =
if (cell.toLowerCase() === 'failed') {
return <CBadge color="danger">{CellTip('Failed to retrieve from API')}</CBadge>
}
if (cell.toLowerCase().startsWith('http')) {
return <a href={`${cell}`}>URL</a>
}
return CellTip(cell)
}
if (typeof cell === 'number') {
Expand Down
7 changes: 7 additions & 0 deletions src/components/utilities/CippActionsOffcanvas.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,13 @@ export default function CippActionsOffcanvas(props) {
title: 'Confirm',
onConfirm: () => genericGetRequest({ path: modalUrl }),
})
} else if (modalType === 'codeblock') {
ModalService.open({
data: modalBody,
componentType: 'codeblock',
title: 'Info',
size: 'lg',
})
} else {
ModalService.confirm({
key: modalContent,
Expand Down
5 changes: 5 additions & 0 deletions src/components/utilities/SharedModal.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import React from 'react'
import { CButton, CModal, CModalBody, CModalFooter, CModalHeader, CModalTitle } from '@coreui/react'
import PropTypes from 'prop-types'
import { CippTable } from 'src/components/tables'
import CippCodeBlock from 'src/components/utilities/CippCodeBlock'

/**
*
Expand All @@ -18,6 +19,10 @@ function mapBodyComponent({ componentType, data, componentProps }) {
return <div>{Array.isArray(data) && data.map((el, idx) => <div key={idx}>{el}</div>)}</div>
case 'text':
return String(data)
case 'codeblock':
return (
<CippCodeBlock language="text" code={data} showLineNumbers={false} {...componentProps} />
)
default:
return String(data)
}
Expand Down
Loading

0 comments on commit 2fc4903

Please sign in to comment.