sp-dev-fx-webparts icon indicating copy to clipboard operation
sp-dev-fx-webparts copied to clipboard

Clicking on the 'my teams' button make the webpart invisible

Open MoeIcI opened this issue 3 years ago • 1 comments

Disclaimer

Yes

Sample

https://github.com/pnp/sp-dev-fx-webparts/tree/main/samples/react-groups-teams

Author(s)

@SamC148 @ReactIntern

What happened?

The Button for Micrsosoft 365 Groups works perfectly fine. The other button makes the webpart invisible. It's not crashing (according to the monitored details for the app). After reloading the page with this webpart, its visible again, but clicking the 'My Teams' Button makes it disappear again.

I'm running these tests on a tenant provided by the developer program

example

Steps to reproduce

  1. Clone the repo
  2. install dependencies (including some fixed due to the sample's age)
  3. gulp bundle & package-solution
  4. Adding to app catalog
  5. approving the requested API permission
  6. putting the webpart on a site.

Expected behavior

Running the webpart as shown in the sample's page.

Target SharePoint environment

SharePoint Online

Developer environment

Windows

Browsers

  • [ ] Internet Explorer
  • [X] Microsoft Edge
  • [ ] Google Chrome
  • [ ] FireFox
  • [ ] Safari
  • [ ] mobile (iOS/iPadOS)
  • [ ] mobile (Android)
  • [ ] not applicable
  • [ ] other (enter in the "Additional environment details" area below)

Paste the results of SPFx doctor

√ SharePoint Framework v1.12.1 √ Node v14.19.3 √ yo v3.1.1 √ gulp v4.0.2 √ bundled typescript used

Additional environment details

No response

MoeIcI avatar Sep 19 '22 06:09 MoeIcI

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

ghost avatar Sep 19 '22 06:09 ghost

Hi @MoeIcI I tried to add the webpart in dev Tenant, but it worked fine. Could you please send a screenshot of the console of your browser after the webpart becomes invisible.

mohammadamer avatar Oct 07 '22 21:10 mohammadamer

Hi @mohammadamer Thanks for helping me out! I appreciate it! I tried it in my dev tenant again, but still the same results. Here is a screenshot in my console:

Screenshot

It seems to be this part, but I don't know how to deal with that: Line 174 in the MyTeams.tsx file {this.state.MyGroupsresultsFiltered.map(Team => { Team.Visibility = Team.Visibility.substr(0, 1).toUpperCase() + Team.Visibility.substr(1); var GroupEmailSplit = Team.Mail.split("@"); var Mail = GroupEmailSplit[0]; return ( ... );

MoeIcI avatar Oct 10 '22 06:10 MoeIcI

Hi @MoeIcI Thanks for the info. Ok, let me double check this part of the code.

mohammadamer avatar Oct 10 '22 07:10 mohammadamer

This issue has been marked as stale due to no progress in over 90 days. If you are still experiencing this issue, please provide additional information so we can help you resolve it.

github-actions[bot] avatar Jan 16 '23 02:01 github-actions[bot]

Closing this issue due to lack of activity. If you are still encountering this issue, please do not hesitate to open a new issue. Make sure to follow the guidance on how to create good issues to increase your chances of getting the help you deserve.

github-actions[bot] avatar Jan 24 '23 02:01 github-actions[bot]