Commit Graph

1267 Commits

Author SHA1 Message Date
Milli
1aa4301840 v1.0.0 2022-05-28 19:57:10 +02:00
Milli
5fe4105dba v1.22.19 2022-05-28 19:56:56 +02:00
Milli
26b7ec9f66 Merge branch 'main' into automated-market-resolution 2022-05-28 16:03:13 +02:00
James Grugett
45f92379bc Portfolio: Fix calculation of whether you sold all your shares 2022-05-28 00:18:09 -05:00
Austin Chen
2ea7ddc1aa Hide mobile bottom bar if Manifold is iframed 2022-05-27 21:27:37 -07:00
Milli
e1591fd0a9 configuration of auto resolution on market creation 2022-05-28 04:19:23 +02:00
Milli
50cee1a6d3 Merge branch 'main' into automated-market-resolution
# Conflicts:
#	common/contract.ts
#	functions/src/create-contract.ts
#	web/pages/create.tsx
2022-05-28 00:41:38 +02:00
Milli
f0dc00e6ad Merge branch 'main' into automated-market-resolution
# Conflicts:
#	web/components/choices-toggle-group.tsx
#	web/pages/create.tsx
2022-05-27 23:11:22 +02:00
Marshall Polaris
86625798cd
Clean up some mess related to nullable collectedFees (#352)
* contract.collectedFees is no longer sometimes nonexistent

* Fix typing issues around payouts code
2022-05-27 14:02:02 -07:00
James Grugett
279b139556 Add 'sold' filter option in portfolio page 2022-05-27 15:51:55 -05:00
James Grugett
15d203977a Portfolio: Consistently filter out contracts you have sold out of. 2022-05-27 15:40:52 -05:00
Forrest Wolf
1e0845f4b9
Replace some uses of any with more specific types (#344)
* Add tsconfig.json for common

* Prefer `const` over `let` over `var`

* Kill dead code

* Fix some trivial Typescript issues

* Turn on Typescript linting in common except for no-explicit-any

* Correctly specify tsconfig dir name in functions eslintrc

* Give react children explicit types

* Add explicit types to removeUndefinedProps

* Create StripeSession type

* Give event in Dropdown an explicit type

* Revert "Give event in Dropdown an explicit type"

This reverts commit 80604310f2.

* Give bids in NewBidTable an explicit type

* Cast results of removeUndefinedProps when neccessary

* Fix type of JoinSpans

* Revert "Cast results of removeUndefinedProps when neccessary"

This reverts commit 5541617bc8.

* Revert "Add explicit types to removeUndefinedProps"

This reverts commit ccf8ffb0b5.

* Give React children types everywhere

* Give event a type

* Give event correct type

* Lint

* Standardize React import

Co-authored-by: Marshall Polaris <marshall@pol.rs>
2022-05-26 15:22:44 -07:00
Marshall Polaris
420ea9e90e
Add more linting to web package (#343)
* Import React a lot

* Fix misc. linting concerns

* Turn on many recommended lints for `web` package
2022-05-26 14:41:24 -07:00
Marshall Polaris
5217270073
Serious business API validation & big cleanup of createContract, placeBet (#302)
* Add the great Zod as a dependency to help us

* Tweak eslint

* Rewrite a ton of stuff in createContract and placeBet

* Clean up error reporting in API

* Make sure the UI is enforcing validated limits on lengths

* Remove unnecessary Math.abs

* Better type on `BetInfo`

* Kill `manaLimitPerUser`

* Clean up hacky parameters on bet info functions

* Validate `closeTime` as a valid timestamp in the future
2022-05-26 14:37:51 -07:00
mantikoros
7b0be014eb show resolved n/a for numeric markets 2022-05-26 09:39:14 -05:00
Milli
a618a43071 created const for resolutions 2022-05-26 14:57:59 +02:00
Milli
66971ed204 string or number array to mixed array 2022-05-26 14:47:32 +02:00
Ian Philips
6f23c16df7 Show up arrow if shares in numeric markets 2022-05-26 06:23:22 -06:00
Milli
5f8031c155 Merge branch 'main' into automated-market-resolution 2022-05-26 13:03:58 +02:00
Sinclair Chen
38fa58406d Fix embeds on incognito (blocked localStorage) 2022-05-25 22:30:03 -07:00
Austin Chen
eb68d059e2 Extend analytics to 90 days 2022-05-25 19:22:50 -07:00
Marshall Polaris
b8b1c0d056
Add tsconfig, more linting to common package (#324)
* Add tsconfig.json for common

* Prefer `const` over `let` over `var`

* Kill dead code

* Fix some trivial Typescript issues

* Turn on Typescript linting in common except for no-explicit-any

* Correctly specify tsconfig dir name in functions eslintrc
2022-05-25 17:12:36 -07:00
Ian Philips
0c3fa9f065
Handle free response outcomes for yes/no shares (#338) 2022-05-25 16:51:33 -06:00
Ian Philips
1334840ee0
Fix comment links from /activity & add to emails (#320) 2022-05-25 16:47:08 -06:00
Ian Philips
f0d44be2f4 Clean up time diff code 2022-05-25 16:04:14 -06:00
Ian Philips
f3be3b1f3c Maybe free market countdown will work now, beats me 2022-05-25 15:55:50 -06:00
Milli
f73883c29a added automatic resolution to contract overview 2022-05-25 22:19:23 +02:00
Milli
a95b9909fe added automatic resolution to contract 2022-05-25 22:18:11 +02:00
Milli
831591b080 restricted automatic resolution to binary markets 2022-05-25 22:17:38 +02:00
Milli
45d7bdd0cd Added combined resolution and required buttons to market creation 2022-05-25 21:37:16 +02:00
Ian Philips
d117ff600a Adjust spacing on % input 2022-05-25 12:47:44 -06:00
Milli
9edc389719 Expanded ChoicesToggleGroup for string choices 2022-05-25 20:45:02 +02:00
Milli
4ddeaa1241 added union type for resolution 2022-05-25 20:27:26 +02:00
Ian Philips
959ee5f8d1
Improve create market UI (#336)
* Move to tailwindui

* Remove commented code

* Prettier

* Show custom prob toggle, limit to 5-95%

* match left margin

* Show prob, date, time, other ui changes

* fix for firefox
2022-05-25 12:13:51 -06:00
Ian Philips
d69f4f9a0a
Move to tailwindui for create market page (#332)
* Move to tailwindui

* Remove commented code

* Prettier

* Show custom prob toggle, limit to 5-95%

* match left margin

* Show prob, date, time, other ui changes
2022-05-25 11:54:28 -06:00
James Grugett
92df092ad3 Fix DOM error in console 2022-05-25 11:48:37 -05:00
Forrest Wolf
c5763e6ec3
Extract signup prompt (#333)
* Extract SignUpPrompt component

* Return null instead of false when not showing SignUpPrompt

* Add trailing newline

* Lint
2022-05-25 09:25:39 -07:00
Milli
9b6e551bad Removed 'automatic' resolution 2022-05-25 17:38:56 +02:00
Ian Philips
1942e1c47a
Show just first 3 letters and chosen answer on fr cards (#318)
* Show just first 3 letters and chosen answer

* 3 dots

* Just show resolved and the chosen answer

* Remove unused truncate & hide resolved except on xs
2022-05-25 07:13:33 -06:00
Austin Chen
eef5dda0f3 Shrink card margin between question & % 2022-05-24 17:25:23 -07:00
Austin Chen
d5a362502a Display liquidity "pool" instead of "bet" volume 2022-05-24 16:57:34 -07:00
Austin Chen
8715ff2740 Semibold the question on cards 2022-05-24 16:39:50 -07:00
Austin Chen
f9336c00be
Preview the quick bet result on hover (#319)
* Switch from triangle to a circle arrow

WIP

* Revert "Switch from triangle to a circle arrow"

This reverts commit 370f8eefe4.

* Show amount moved in probability

* Animate the prob bar change too

* Pull out quick bet display component

* Minor cleanups

* Clean up comments

* Close empty divs

* Feedback from Ian

* Pull out constant

* Get rid of quick bet separators

* Fix typescript change

* Invert colors so gray indicates placed bets

* Update comment on useSaveShares re: Ian's comments
2022-05-24 16:38:43 -07:00
Marshall Polaris
2d8ad40e70
Add outcome type to API market descriptors (#325) 2022-05-24 14:31:49 -07:00
Milli
645e891b73 Added radio buttons to market creation (non functional) 2022-05-24 18:47:21 +02:00
mantikoros
c3be126337
Revert "Update leaderboards.tsx (#314)" (#317)
This reverts commit d19d60eb6a.
2022-05-24 09:31:42 -05:00
Ian Philips
811a7cece7 Market => question 2022-05-24 08:28:09 -06:00
Ian Philips
49bfb67daa Revert to showing FR answer 2022-05-24 08:24:01 -06:00
Ian Philips
13bf5ac253 Free daily market bugfix 2022-05-24 07:31:44 -06:00
SirSaltyy
d19d60eb6a
Update leaderboards.tsx (#314)
Renamed top creators header from "market volume" to "market liquidity".
2022-05-24 14:05:12 +01:00