~razzi/weave

f720feebc81059ced919572be48cb286c84efa92 — Razzi Abuissa 7 months ago 1882988 parcel
Change tooltips to titles, remove react-tooltip
M package.json => package.json +12 -4
@@ 30,7 30,6 @@
    "react-select": "^5.7.4",
    "react-slick": "^0.29.0",
    "react-toggle-switch": "^3.0.4",
    "react-tooltip": "^5.21.1",
    "slick-carousel": "^1.8.1",
    "url-polyfill": "^1.1.12"
  },


@@ 43,8 42,7 @@
    "eslint-plugin-import": "^2.28.1",
    "eslint-plugin-jsx-a11y": "^6.7.1",
    "eslint-plugin-react": "^7.33.2",
    "prettier": "^3.0.2",
    "process": "^0.11.10"
    "prettier": "^3.0.2"
  },
  "prettier": {
    "trailingComma": "es5",


@@ 54,5 52,15 @@
  "browserslist": [
    "defaults"
  ],
  "proxy": "http://localhost:5000"
  "proxy": "http://localhost:5000",
  "targets": {
    "default": {
      "engines": {
        "browsers": ">= 50%"
      },
      "distDir": "dist/assets",
      "sourceMap": false,
      "publicUrl": "/assets"
    }
  }
}

M src/App.js => src/App.js +1 -7
@@ 2,7 2,6 @@ import React, { Component } from 'react'
import { BrowserRouter as Router, Link, Route, Switch } from 'react-router-dom'

import Toggle from 'react-toggle-switch'
import { Tooltip } from 'react-tooltip'

import 'slick-carousel/slick/slick.css'
import 'slick-carousel/slick/slick-theme.css'


@@ 110,15 109,10 @@ class App extends Component {

    const availableForMentoringToggle = account && (
      <div
        data-tip
        title="Controls whether your profile will be visible to mentees."
        className="available-for-mentoring"
        data-for="toggleTooltip"
      >
        Available&nbsp;for&nbsp;mentoring:
        <Tooltip id="toggleTooltip" place="bottom">
          Controls whether your profile will be visible to mentees.
          {account.profileId === null && ' You have not yet created a profile.'}
        </Tooltip>
        <Toggle
          enabled={Boolean(account.profileId)}
          on={account.availableForMentoring}

M src/CheckboxIndicator.js => src/CheckboxIndicator.js +1 -4
@@ 1,6 1,5 @@
import React from 'react'
import MediaQuery from 'react-responsive'
import { Tooltip } from 'react-tooltip'

function CheckboxIndicator({ title, checked }) {
  const checkbox = (


@@ 30,10 29,8 @@ function CheckboxIndicator({ title, checked }) {
          type="button"
          onClick={(e) => {
            e.preventDefault()
            Tooltip.show()
          }}
          data-tip={title}
          data-for="indicator"
          title={title}
        >
          {checkbox}
        </button>

M src/ProfileForm.js => src/ProfileForm.js +2 -2
@@ 510,7 510,7 @@ export default class ProfileForm extends Component {
                Englander, Christian, Latino, LGBTQ+
              </p>
            </div>
            <div data-tip="Please feel free to create your own tags with identities or locations that are important to you.">
            <div>
              <p>Parts Of Me</p>
              <CreatableInputOnly
                values={partsOfMe}


@@ 518,7 518,7 @@ export default class ProfileForm extends Component {
                handleChange={this.handleChange('partsOfMe')}
              />
            </div>
            <div data-tip="Please feel free to create your own tags with activities that you enjoy.">
            <div>
              <p>Activities I Enjoy</p>
              <CreatableTagSelect
                values={activities}

M src/ProfileView.js => src/ProfileView.js +1 -6
@@ 1,7 1,6 @@
import React, { Fragment, useState } from 'react'
import MediaQuery from 'react-responsive'
import { withRouter } from 'react-router-dom'
import { Tooltip } from 'react-tooltip'

import { starProfile, unstarProfile } from './api'
import Button from './Button'


@@ 235,11 234,7 @@ function ProfileView({
          <div className="columns">
            <div className="column contact">
              {profileId != null && !ownProfile && (
                <div data-tip data-for="starTooltip">
                  <Tooltip id="starTooltip" place="top">
                    Click here to{' '}
                    {starredState ? 'remove star' : 'mark profile as starred'}
                  </Tooltip>
                <div title="Click here to star/unstar profile">
                  <ProfileStar
                    active={starredState}
                    onClick={() => {

M src/ResultsView.js => src/ResultsView.js +0 -2
@@ 1,5 1,4 @@
import React from 'react'
import { Tooltip } from 'react-tooltip'
import ProfileResult from './ProfileResult'
import Button from './Button'



@@ 68,7 67,6 @@ function ResultsView({
          </button>
        )}
      </p>
      <Tooltip id="indicator" place="bottom" />
      <div>{profileElements}</div>
      {navigationButtons}
    </div>

M src/SubmitEmailForm.js => src/SubmitEmailForm.js +1 -7
@@ 1,6 1,5 @@
import React, { Component } from 'react'
import { Link } from 'react-router-dom'
import { Tooltip } from 'react-tooltip'

import { getParam } from './utils'
import VALID_DOMAINS from './valid_domains.json'


@@ 80,9 79,6 @@ export default class SubmitEmailForm extends Component {
                value={email}
              />
            </p>
            <Tooltip place="bottom" id="emailTooltip">
              Please enter your Duke or hospital-affiliated email
            </Tooltip>

            {error && <p className="error">{error}</p>}
            <div>


@@ 98,10 94,8 @@ export default class SubmitEmailForm extends Component {
              This is a personal device (stay logged in for 2 weeks)
            </div>
            <div
              title="Please enter your Duke-affililated email"
              id="toggle"
              data-tip
              data-for="emailTooltip"
              data-tip-disable={email === '' || emailValid}
            >
              <button type="submit" disabled={!emailValid} className="button">
                Send verification email

M yarn.lock => yarn.lock +2 -10
@@ 345,7 345,7 @@
  dependencies:
    "@floating-ui/utils" "^0.1.1"

"@floating-ui/dom@^1.0.0", "@floating-ui/dom@^1.0.1":
"@floating-ui/dom@^1.0.1":
  version "1.5.1"
  resolved "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.5.1.tgz"
  integrity sha512-KwvVcPSXg6mQygvA1TjbN/gh///36kKtllIF8SUm0qpFj8+rvYrpvlYdL1JoA71SHpDqgSSdGOSoQ0Mp3uY5aw==


@@ 1604,7 1604,7 @@ chrome-trace-event@^1.0.2, chrome-trace-event@^1.0.3:
  resolved "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.3.tgz"
  integrity sha512-p3KULyQg4S7NIHixdwbGX+nFHkoBiA4YQmyWtjb8XngSKV124nJmRysgAeujbUVb15vh+RvFUfCPqU7rXk+hZg==

classnames@^2.2.5, classnames@^2.3.0:
classnames@^2.2.5:
  version "2.3.2"
  resolved "https://registry.npmjs.org/classnames/-/classnames-2.3.2.tgz"
  integrity sha512-CSbhY4cFEJRe6/GQzIk5qXZ4Jeg5pcsP7b5peFSDpffpe1cqjASH/n9UTjBwOp6XpMSTwQ8Za2K5V02ueA7Tmw==


@@ 3424,14 3424,6 @@ react-toggle-switch@^3.0.4:
  resolved "https://registry.npmjs.org/react-toggle-switch/-/react-toggle-switch-3.0.4.tgz"
  integrity sha512-eM2Izl0qNrdFZlmRwpXPpUjaYVISHVy8dxCN9l6eRZ7KpmrDsIGInDpoSRU2QPs596+Al+udOArdXX5wCRg0Gg==

react-tooltip@^5.21.1:
  version "5.21.1"
  resolved "https://registry.npmjs.org/react-tooltip/-/react-tooltip-5.21.1.tgz"
  integrity sha512-wJqF/yzK1wuJuy5/zAkVErFA609fVv1ZukhGjw44PcMvg9wL0jomnpQyz3qH1H7TWjz/wqO/OMc3ipQNjZ8zYg==
  dependencies:
    "@floating-ui/dom" "^1.0.0"
    classnames "^2.3.0"

react-transition-group@^4.3.0:
  version "4.4.5"
  resolved "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.5.tgz"