Added sample.json and dev container
|
@ -2,12 +2,12 @@
|
||||||
|
|
||||||
## Summary
|
## Summary
|
||||||
|
|
||||||
This SPFx app alows quick access to user agenda, ToDo Tasks, Files and News and Relevenat People related to user.
|
This SPFx app allows quick access to user agenda, ToDo Tasks, Files and News and Relevant People related to user.
|
||||||
|
|
||||||
![react-my-dashboard](./src/assets/MyDashboard_dark.png)
|
![react-my-dashboard](./assets/MyDashboard_dark.png)
|
||||||
![react-my-dashboard](./src/assets/MyDashboard_sp.png)
|
![react-my-dashboard](./assets/MyDashboard_sp.png)
|
||||||
![react-my-dashboard](./src/assets/MyDashboard_office.png)
|
![react-my-dashboard](./assets/MyDashboard_office.png)
|
||||||
![react-my-dashboard](./src/assets/mobileTeamsApp02.PNG) ![react-my-dashboard](./src/assets/mobileTeamsApp01.PNG) ![react-my-dashboard](./src/assets/mobileTeamsApp03.PNG)
|
![react-my-dashboard](./assets/mobileTeamsApp02.PNG) ![react-my-dashboard](./assets/mobileTeamsApp01.PNG) ![react-my-dashboard](./assets/mobileTeamsApp03.PNG)
|
||||||
|
|
||||||
## Compatibility
|
## Compatibility
|
||||||
|
|
||||||
|
@ -16,7 +16,7 @@ This SPFx app alows quick access to user agenda, ToDo Tasks, Files and News and
|
||||||
| Every SPFx version is only compatible with specific version(s) of Node.js. In order to be able to build this sample, please ensure that the version of Node on your workstation matches one of the versions listed in this section. This sample will not work on a different version of Node.|
|
| Every SPFx version is only compatible with specific version(s) of Node.js. In order to be able to build this sample, please ensure that the version of Node on your workstation matches one of the versions listed in this section. This sample will not work on a different version of Node.|
|
||||||
|Refer to <https://aka.ms/spfx-matrix> for more information on SPFx compatibility. |
|
|Refer to <https://aka.ms/spfx-matrix> for more information on SPFx compatibility. |
|
||||||
|
|
||||||
![SPFx 1.16.1](https://img.shields.io/badge/SPFx-1.16.1-green.svg)
|
![SPFx 1.17.2](https://img.shields.io/badge/SPFx-1.17.2-green.svg)
|
||||||
![Node.js v16 | v14](https://img.shields.io/badge/Node.js-v16%20|%20v14-green.svg)
|
![Node.js v16 | v14](https://img.shields.io/badge/Node.js-v16%20|%20v14-green.svg)
|
||||||
![SharePoint Online](https://img.shields.io/badge/SharePoint-Online-yellow.svg)
|
![SharePoint Online](https://img.shields.io/badge/SharePoint-Online-yellow.svg)
|
||||||
![Workbench Hosted: Does not work with local workbench](https://img.shields.io/badge/Workbench-Hosted-yellow.svg "Does not work with local workbench")
|
![Workbench Hosted: Does not work with local workbench](https://img.shields.io/badge/Workbench-Hosted-yellow.svg "Does not work with local workbench")
|
||||||
|
@ -29,16 +29,16 @@ This SPFx app alows quick access to user agenda, ToDo Tasks, Files and News and
|
||||||
|
|
||||||
## Prerequisites
|
## Prerequisites
|
||||||
|
|
||||||
This sample use Microsoft Graph Toolkit V3 RC and use the folling components :
|
This sample use Microsoft Graph Toolkit V3 RC and use the following components :
|
||||||
|
|
||||||
- mgt-Agenda
|
* mgt-Agenda
|
||||||
- mgt-ToDo
|
* mgt-ToDo
|
||||||
- mgt-Person and PersonCard
|
* mgt-Person and PersonCard
|
||||||
- mgt-Search-results
|
* mgt-Search-results
|
||||||
- mgt-get
|
* mgt-get
|
||||||
- mgt-files
|
* mgt-files
|
||||||
|
|
||||||
Please add the required Microsoft Graph Permissions. Please see [Microsoft Graph Toolkit overview](https://learn.microsoft.com/en-us/graph/toolkit/overview)
|
Please add the required Microsoft Graph Permissions. Please see [Microsoft Graph Toolkit overview](https://learn.microsoft.com/graph/toolkit/overview)
|
||||||
|
|
||||||
## Contributors
|
## Contributors
|
||||||
|
|
||||||
|
@ -55,7 +55,7 @@ Version|Date|Comments
|
||||||
The project was created with Visual Studio Teams Toolkit.
|
The project was created with Visual Studio Teams Toolkit.
|
||||||
|
|
||||||
* Clone this repository
|
* Clone this repository
|
||||||
* Navigate to src folder
|
* Navigate to `src` folder
|
||||||
* in the command line run:
|
* in the command line run:
|
||||||
* `npm install`
|
* `npm install`
|
||||||
* `gulp build`
|
* `gulp build`
|
||||||
|
@ -67,7 +67,6 @@ The project was created with Visual Studio Teams Toolkit.
|
||||||
|
|
||||||
## Features
|
## Features
|
||||||
|
|
||||||
|
|
||||||
This sample illustrates the following concepts on top of the SharePoint Framework:
|
This sample illustrates the following concepts on top of the SharePoint Framework:
|
||||||
|
|
||||||
* using React for building SharePoint Framework client-side web parts
|
* using React for building SharePoint Framework client-side web parts
|
||||||
|
@ -75,10 +74,7 @@ This sample illustrates the following concepts on top of the SharePoint Framewor
|
||||||
* Using React Hooks
|
* Using React Hooks
|
||||||
* using Global State Management (JOTAI)
|
* using Global State Management (JOTAI)
|
||||||
* using FLuentUI V9
|
* using FLuentUI V9
|
||||||
* using Visuatl Studio Teams Toolkit
|
* using Visual Studio Teams Toolkit
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## References
|
## References
|
||||||
|
|
||||||
|
@ -95,11 +91,11 @@ We do not support samples, but we this community is always willing to help, and
|
||||||
|
|
||||||
If you're having issues building the solution, please run [spfx doctor](https://pnp.github.io/cli-microsoft365/cmd/spfx/spfx-doctor/) from within the solution folder to diagnose incompatibility issues with your environment.
|
If you're having issues building the solution, please run [spfx doctor](https://pnp.github.io/cli-microsoft365/cmd/spfx/spfx-doctor/) from within the solution folder to diagnose incompatibility issues with your environment.
|
||||||
|
|
||||||
If you encounter any issues while using this sample, [create a new issue](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Abug-suspected%2Csample%3A%20react-birthdays&template=bug-report.yml&sample=react-birthdays&authors=@smaity%20@joaojmendes&title=react-birthdays%20-%20).
|
If you encounter any issues while using this sample, [create a new issue](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Abug-suspected%2Csample%3A%20react-my-dashboard&template=bug-report.yml&sample=react-my-dashboard&authors=@smaity%20@joaojmendes&title=react-my-dashboard%20-%20).
|
||||||
|
|
||||||
For questions regarding this sample, [create a new question](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Aquestion%2Csample%3A%20react-birthdays&template=question.yml&sample=react-birthdays&authors=@smaity%20@joaojmendes&title=react-birthdays%20-%20).
|
For questions regarding this sample, [create a new question](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Aquestion%2Csample%3A%20react-my-dashboard&template=question.yml&sample=react-my-dashboard&authors=@smaity%20@joaojmendes&title=react-my-dashboard%20-%20).
|
||||||
|
|
||||||
Finally, if you have an idea for improvement, [make a suggestion](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Aenhancement%2Csample%3A%20react-birthdays&template=question.yml&sample=react-birthdays&authors=@smaity%20@joaojmendes&title=react-birthdays%20-%20).
|
Finally, if you have an idea for improvement, [make a suggestion](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Aenhancement%2Csample%3A%20react-my-dashboard&template=question.yml&sample=react-my-dashboard&authors=@smaity%20@joaojmendes&title=react-my-dashboard%20-%20).
|
||||||
|
|
||||||
## Disclaimer
|
## Disclaimer
|
||||||
|
|
Before Width: | Height: | Size: 945 KiB After Width: | Height: | Size: 945 KiB |
Before Width: | Height: | Size: 975 KiB After Width: | Height: | Size: 975 KiB |
Before Width: | Height: | Size: 1.9 MiB After Width: | Height: | Size: 1.9 MiB |
Before Width: | Height: | Size: 1.5 MiB After Width: | Height: | Size: 1.5 MiB |
Before Width: | Height: | Size: 474 KiB After Width: | Height: | Size: 474 KiB |
Before Width: | Height: | Size: 720 KiB After Width: | Height: | Size: 720 KiB |
Before Width: | Height: | Size: 522 KiB After Width: | Height: | Size: 522 KiB |
|
@ -0,0 +1,50 @@
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"name": "pnp-sp-dev-spfx-web-parts-react-my-dashboard",
|
||||||
|
"source": "pnp",
|
||||||
|
"title": "My Dashboard",
|
||||||
|
"shortDescription": "This SPFx app allows quick access to user agenda, ToDo Tasks, Files and News and Relevant People related to user.",
|
||||||
|
"url": "https://github.com/pnp/sp-dev-fx-webparts/tree/main/samples/react-my-dashboard",
|
||||||
|
"downloadUrl": "https://pnp.github.io/download-partial/?url=https://github.com/pnp/sp-dev-fx-webparts/tree/main/samples/react-my-dashboard",
|
||||||
|
"longDescription": [
|
||||||
|
"This SPFx app allows quick access to user agenda, ToDo Tasks, Files and News and Relevant People related to user."
|
||||||
|
],
|
||||||
|
"creationDateTime": "2023-06-23",
|
||||||
|
"updateDateTime": "2023-06-23",
|
||||||
|
"products": [
|
||||||
|
"SharePoint"
|
||||||
|
],
|
||||||
|
"metadata": [
|
||||||
|
{
|
||||||
|
"key": "CLIENT-SIDE-DEV",
|
||||||
|
"value": "React"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"key": "SPFX-VERSION",
|
||||||
|
"value": "1.17.2"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"thumbnails": [
|
||||||
|
{
|
||||||
|
"type": "image",
|
||||||
|
"order": 100,
|
||||||
|
"url": "https://github.com/pnp/sp-dev-fx-webparts/raw/main/samples/react-my-dashboard/assets/MyDashboard_default.png",
|
||||||
|
"alt": "Web Part Preview"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"authors": [
|
||||||
|
{
|
||||||
|
"gitHubAccount": "joaojmendes",
|
||||||
|
"pictureUrl": "https://github.com/joaojmendes.png",
|
||||||
|
"name": "João Mendes"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"references": [
|
||||||
|
{
|
||||||
|
"name": "Build your first SharePoint client-side web part",
|
||||||
|
"description": "Client-side web parts are client-side components that run in the context of a SharePoint page. Client-side web parts can be deployed to SharePoint environments that support the SharePoint Framework. You can also use modern JavaScript web frameworks, tools, and libraries to build them.",
|
||||||
|
"url": "https://docs.microsoft.com/sharepoint/dev/spfx/web-parts/get-started/build-a-hello-world-web-part"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
|
@ -0,0 +1,39 @@
|
||||||
|
// For more information on how to run this SPFx project in a VS Code Remote Container, please visit https://aka.ms/spfx-devcontainer
|
||||||
|
{
|
||||||
|
"name": "SPFx 1.17.2",
|
||||||
|
"image": "docker.io/m365pnp/spfx:1.17.2",
|
||||||
|
// Set *default* container specific settings.json values on container create.
|
||||||
|
"settings": {},
|
||||||
|
// Add the IDs of extensions you want installed when the container is created.
|
||||||
|
"extensions": [
|
||||||
|
"editorconfig.editorconfig",
|
||||||
|
"dbaeumer.vscode-eslint"
|
||||||
|
],
|
||||||
|
// Use 'forwardPorts' to make a list of ports inside the container available locally.
|
||||||
|
"forwardPorts": [
|
||||||
|
4321,
|
||||||
|
35729
|
||||||
|
],
|
||||||
|
"portsAttributes": {
|
||||||
|
"4321": {
|
||||||
|
"protocol": "https",
|
||||||
|
"label": "Manifest",
|
||||||
|
"onAutoForward": "silent",
|
||||||
|
"requireLocalPort": true
|
||||||
|
},
|
||||||
|
// Not needed for SPFx>= 1.12.1
|
||||||
|
// "5432": {
|
||||||
|
// "protocol": "https",
|
||||||
|
// "label": "Workbench",
|
||||||
|
// "onAutoForward": "silent"
|
||||||
|
// },
|
||||||
|
"35729": {
|
||||||
|
"protocol": "https",
|
||||||
|
"label": "LiveReload",
|
||||||
|
"onAutoForward": "silent",
|
||||||
|
"requireLocalPort": true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"postCreateCommand": "bash .devcontainer/spfx-startup.sh",
|
||||||
|
"remoteUser": "node"
|
||||||
|
}
|
|
@ -0,0 +1,33 @@
|
||||||
|
echo
|
||||||
|
echo -e "\e[1;94mInstalling Node dependencies\e[0m"
|
||||||
|
npm install
|
||||||
|
|
||||||
|
## commands to create dev certificate and copy it to the root folder of the project
|
||||||
|
echo
|
||||||
|
echo -e "\e[1;94mGenerating dev certificate\e[0m"
|
||||||
|
gulp trust-dev-cert
|
||||||
|
|
||||||
|
# Convert the generated PEM certificate to a CER certificate
|
||||||
|
openssl x509 -inform PEM -in ~/.rushstack/rushstack-serve.pem -outform DER -out ./spfx-dev-cert.cer
|
||||||
|
|
||||||
|
# Copy the PEM ecrtificate for non-Windows hosts
|
||||||
|
cp ~/.rushstack/rushstack-serve.pem ./spfx-dev-cert.pem
|
||||||
|
|
||||||
|
## add *.cer to .gitignore to prevent certificates from being saved in repo
|
||||||
|
if ! grep -Fxq '*.cer' ./.gitignore
|
||||||
|
then
|
||||||
|
echo "# .CER Certificates" >> .gitignore
|
||||||
|
echo "*.cer" >> .gitignore
|
||||||
|
fi
|
||||||
|
|
||||||
|
## add *.pem to .gitignore to prevent certificates from being saved in repo
|
||||||
|
if ! grep -Fxq '*.pem' ./.gitignore
|
||||||
|
then
|
||||||
|
echo "# .PEM Certificates" >> .gitignore
|
||||||
|
echo "*.pem" >> .gitignore
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo
|
||||||
|
echo -e "\e[1;92mReady!\e[0m"
|
||||||
|
|
||||||
|
echo -e "\n\e[1;94m**********\nOptional: if you plan on using gulp serve, don't forget to add the container certificate to your local machine. Please visit https://aka.ms/spfx-devcontainer for more information\n**********"
|
|
@ -32,7 +32,7 @@ export const MyFeed: React.FunctionComponent<IFeedProps> = (props: React.PropsWi
|
||||||
const tabs: ITab[] = [
|
const tabs: ITab[] = [
|
||||||
{
|
{
|
||||||
id: "tab1",
|
id: "tab1",
|
||||||
name: strings.CompanyAnnoucements,
|
name: strings.CompanyAnnouncements,
|
||||||
icon: <NewsIcon />,
|
icon: <NewsIcon />,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ define([], function() {
|
||||||
"eventOrganizer":"Organizer",
|
"eventOrganizer":"Organizer",
|
||||||
"Agenda":"Agenda",
|
"Agenda":"Agenda",
|
||||||
"Todo":"Todo",
|
"Todo":"Todo",
|
||||||
"CompanyAnnoucements":"Company Annoucements",
|
"CompanyAnnouncements":"Company Announcements",
|
||||||
"Trending":"Trending",
|
"Trending":"Trending",
|
||||||
"NoNews":"No News to show",
|
"NoNews":"No News to show",
|
||||||
"Files":"Files",
|
"Files":"Files",
|
||||||
|
|
|
@ -5,7 +5,7 @@ declare interface IDashBoardWebPartStrings {
|
||||||
eventOrganizer:string;
|
eventOrganizer:string;
|
||||||
Agenda:string;
|
Agenda:string;
|
||||||
Todo:string;
|
Todo:string;
|
||||||
CompanyAnnoucements:string;
|
CompanyAnnouncements:string;
|
||||||
Trending:string;
|
Trending:string;
|
||||||
NoNews:string;
|
NoNews:string;
|
||||||
Files:string;
|
Files:string;
|
||||||
|
|