-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prettier poll result #245
Merged
antobinary
merged 16 commits into
bigbluebutton:develop
from
hiroshisuga:dev5.0.0_prettyPollPR
Apr 17, 2024
Merged
Prettier poll result #245
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
18a7be6
Update result.js
hiroshisuga 945d608
More general algorithm
hiroshisuga 7a65bf3
[fix] bug in formular
hiroshisuga 9391b42
use arrow function
hiroshisuga 4c5286f
webkit browsers
hiroshisuga 924c0d2
webkit browsers
hiroshisuga eaafc80
getPads function
hiroshisuga a8e81cd
getPads function
hiroshisuga abb4cca
Update result.js
hiroshisuga 16014ac
add bowser
hiroshisuga 72d34cd
Create deviceInfo.js
hiroshisuga bef8bfe
Create browserInfo.js
hiroshisuga 0d0fcd1
Update index.js
hiroshisuga 05158d1
Update src/utils/data/index.js
hiroshisuga ac92346
Update index.js
hiroshisuga 15e29b4
Merge branch 'develop' into dev5.0.0_prettyPollPR
hiroshisuga File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import Bowser from 'bowser'; | ||
|
||
const BOWSER_RESULTS = Bowser.parse(window.navigator.userAgent); | ||
|
||
const isChrome = BOWSER_RESULTS.browser.name === 'Chrome'; | ||
const isSafari = BOWSER_RESULTS.browser.name === 'Safari'; | ||
const isEdge = BOWSER_RESULTS.browser.name === 'Microsoft Edge'; | ||
const isIe = BOWSER_RESULTS.browser.name === 'Internet Explorer'; | ||
const isFirefox = BOWSER_RESULTS.browser.name === 'Firefox'; | ||
|
||
const browserName = BOWSER_RESULTS.browser.name; | ||
const versionNumber = BOWSER_RESULTS.browser.version; | ||
|
||
const isValidSafariVersion = Bowser.getParser(window.navigator.userAgent).satisfies({ | ||
safari: '>12', | ||
}); | ||
|
||
const browserInfo = { | ||
isChrome, | ||
isSafari, | ||
isEdge, | ||
isIe, | ||
isFirefox, | ||
browserName, | ||
versionNumber, | ||
isValidSafariVersion, | ||
}; | ||
|
||
export default browserInfo; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import Bowser from 'bowser'; | ||
|
||
const BOWSER_RESULTS = Bowser.parse(window.navigator.userAgent); | ||
|
||
const isPhone = BOWSER_RESULTS.platform.type === 'mobile'; | ||
// we need a 'hack' to correctly detect ipads with ios > 13 | ||
const isTablet = BOWSER_RESULTS.platform.type === 'tablet' || (BOWSER_RESULTS.os.name === 'macOS' && window.navigator.maxTouchPoints > 0); | ||
const isMobile = isPhone || isTablet; | ||
const hasMediaDevices = !!navigator.mediaDevices; | ||
const osName = BOWSER_RESULTS.os.name; | ||
const osVersion = BOWSER_RESULTS.os.version; | ||
const isIos = osName === 'iOS'; | ||
const isMacos = osName === 'macOS'; | ||
const isIphone = !!(window.navigator.userAgent.match(/iPhone/i)); | ||
|
||
const SUPPORTED_IOS_VERSION = 12.2; | ||
const isIosVersionSupported = () => parseFloat(osVersion) >= SUPPORTED_IOS_VERSION; | ||
|
||
const isPortrait = () => window.innerHeight > window.innerWidth; | ||
|
||
const deviceInfo = { | ||
isTablet, | ||
isPhone, | ||
isMobile, | ||
hasMediaDevices, | ||
osName, | ||
isPortrait, | ||
isIos, | ||
isMacos, | ||
isIphone, | ||
isIosVersionSupported, | ||
}; | ||
|
||
export default deviceInfo; |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just out of curiosity, what is the difference between the EN and the Figure spaces?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After some experiment, I've found FIGURE_SPACE does not work for Firefox and EN_SPACE is better. I don't know the difference in detail, but by definition EN_SPACE is 1/2 em. And FIGURE_SPACE should have the same size of digit zero of a fixed font. However, there are somebody saying that it's not guaranteed....