Commit graph

30 commits

Author SHA1 Message Date
83d41428eb Feature rewrite
- Removed `jsx()` and `JSXFunction`. You can now use `JSX.Element` like any other `Computable` value
- `joinJSX` now always requires a joiner. Just pass the array of elements or wrap them in `<>` and `</>` if there's no joiner
- Removed `coerceComponent`, `computeComponent`, and `computeOptionalComponent`; just use the `render` function now
- It's recommended to now do `<MyComponent />` instead of `<component :is="myComponent" />`
- All features no longer take the options as a type parameter, and all generic forms have been removed as a result
- Fixed `forceHideGoBack` not being respected
- Removed `deepUnref` as now things don't get unreffed before being passed into vue components by default
- Moved MarkNode to new wrapper, and removed existing `mark` properties
- Moved Tooltip to new wrapper, and made it take an options function instead of raw object
- VueFeature component now wraps all vue features, and applies styling, classes, and visibility in the wrapping div. It also adds the Node component so features don't need to
- `mergeAdjacent` now works with grids (perhaps should've used scss to reduce the amount of css this took)
- `CoercableComponent` renamed to `Renderable` since it should be used with `render`
- Replaced `isCoercableComponent` with `isJSXElement`
- Replaced `Computable` and `ProcessedComputable` with the vue built-ins `MaybeRefOrGetter` and `MaybeRef`
- `convertComputable` renamed to `processGetter`
- Also removed `GetComputableTypeWithDefault` and `GetComputableType`, which can similarly be replaced
- `dontMerge` is now a property on rows and columns rather than an undocumented css class you'd have to include on every feature within the row or column
- Fixed saves manager not being imported in addiction warning component
- Created `vueFeatureMixin` for simplifying the vue specific parts of a feature. Passes the component's properties in explicitly and directly from the feature itself
- All features should now return an object that includes props typed to omit the options object and satisfies the feature. This will ensure type correctness and pass-through custom properties. (see existing features for more thorough examples of changes)
- Replaced decorators with mixins, which won't require casting. Bonus amount decorators converted into generic bonus amount mixin. Removed effect decorator
- All `render` functions now return `JSX.Element`. The `JSX` variants (e.g. `renderJSX`) (except `joinJSX`) have been removed
- Moved all features that use the clickable component into the clickable folder
- Removed `small` property from clickable, since its a single css rule (`min-height: unset`) (you could add a small css class and pass small to any vue feature's classes property, though)
- Upgrades now use the clickable component
- Added ConversionType symbol
- Removed setDefault, just use `??=`
- Added isType function that uses a type symbol to check
- General cleanup
2024-11-29 08:02:24 -06:00
4987916900 Fix last lint issue 2024-10-20 13:51:31 -05:00
1e5411d279 Remove processedPropType and convert all components to composition API 2024-10-20 05:47:59 -05:00
052a01d3f7 Fix build issues 2024-10-18 09:26:10 -05:00
88abd53faf Update eslint and prettier 2024-10-18 07:04:33 -05:00
80d7a743bc Update TS 2024-10-18 07:04:29 -05:00
563eaa7539 Lint 2024-03-29 00:19:57 -05:00
6ad08c4052 Fix camelCase props not working on links 2023-05-21 17:27:29 -05:00
d3f5e3bed7 Fix some merge issues 2023-02-15 21:08:10 -06:00
4a28c2f8f9 Remove showIf and make visibility properties take booleans 2023-02-15 20:54:56 -06:00
9b49aedccb Add eslint rule for strict boolean expressions and fix linting issues 2022-12-20 21:33:23 -06:00
1729fa8561 Add joinJSX utility function 2022-08-22 08:51:37 -05:00
39c62f3b9c Made trackHover less intrusive 2022-07-27 22:58:59 -05:00
783d5a8a6b Add function to track hovering over a VueFeature 2022-07-26 19:51:39 -05:00
ab81a140c9 Make all type-only imports explicit 2022-06-26 19:17:22 -05:00
7fe57798bb Switched from vue-cli-service to vite
Should be thoroughly tested still
Also involved removing operator overloads, which weren't good anyways
2022-06-25 22:34:18 -05:00
d650cda84f Using getFirstFeature and Collapsible won't re-render each frame 2022-05-23 22:54:48 -05:00
d988b37e8d Clean up typing 2022-04-23 22:14:47 -05:00
f76d5deb6e Tooltips overhaul 2022-04-23 22:14:45 -05:00
c918f1b54b Add render functions that ensure returned type is always a JSX element 2022-04-23 22:14:29 -05:00
3fa7ccf0c1 Added collapsibles 2022-03-27 19:23:20 -05:00
561dd35570 Added events to onClick 2022-03-27 00:47:34 -05:00
563bf76bee setupHoldToClick calls stop on unmount 2022-03-11 17:01:22 -06:00
7524ed3164 Export more types 2022-03-08 19:40:51 -06:00
49474b1518 Changed path aliasing 2022-03-03 21:39:48 -06:00
5beecba267 Have features register settings fields dynamically 2022-02-27 16:41:39 -06:00
a8af84f581 Reorganized components 2022-02-27 16:04:56 -06:00
e2126472b2 Fixed runtime issues with vue
Entire demo tree has been tested and is fully functional,
including all the options and save manager functionality
2022-02-27 13:49:34 -06:00
90e49e196f Fixing more issues 2022-01-24 22:25:34 -06:00
6f781b33fa New layer API WIP 2022-01-13 22:25:47 -06:00