Skip to content

Commit

Permalink
Merge branch 'main' into chore/upgrade-dependency-sprint41
Browse files Browse the repository at this point in the history
  • Loading branch information
airslice committed Aug 8, 2023
2 parents 22b60ba + 17b2566 commit 14645d1
Show file tree
Hide file tree
Showing 21 changed files with 195 additions and 104 deletions.
1 change: 0 additions & 1 deletion .github/workflows/ci_server.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ jobs:

ci-server-test:
runs-on: ubuntu-latest
if: github.event_name != 'push' || !startsWith(github.event.head_commit.message, 'v')
services:
mongo:
image: mongo:5-focal
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/ci_web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ jobs:
ci:
name: ci
runs-on: ubuntu-latest
if: github.event_name != 'push' || !startsWith(github.event.head_commit.message, 'v')
defaults:
run:
working-directory: web
Expand Down
96 changes: 96 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,102 @@

All notable changes to this project will be documented in this file.

## 0.18.0 - 2023-08-07

### Web

#### 🚀 Features

- Add VisualizerContext in NLS for beta ([#591](https://github.com/reearth/reearth/pull/591)) [`39811d`](https://github.com/reearth/reearth/commit/39811d)
- New beta modal design ([#579](https://github.com/reearth/reearth/pull/579)) [`517b1b`](https://github.com/reearth/reearth/commit/517b1b)
- Support google photorealistic ([#521](https://github.com/reearth/reearth/pull/521)) [`ca71b3`](https://github.com/reearth/reearth/commit/ca71b3)
- Support IBL for terrain ([#529](https://github.com/reearth/reearth/pull/529)) [`743963`](https://github.com/reearth/reearth/commit/743963)
- Support HBAO ([#569](https://github.com/reearth/reearth/pull/569)) [`d5b3c9`](https://github.com/reearth/reearth/commit/d5b3c9)

#### 🔧 Bug Fixes

- Wrong type error [`88ee7e`](https://github.com/reearth/reearth/commit/88ee7e)
- Unsafe builtin implementation ([#623](https://github.com/reearth/reearth/pull/623)) [`96faac`](https://github.com/reearth/reearth/commit/96faac)
- Revert small change [`aa8680`](https://github.com/reearth/reearth/commit/aa8680)
- Pr preview build failing ([#614](https://github.com/reearth/reearth/pull/614)) [`031295`](https://github.com/reearth/reearth/commit/031295)
- Crash app by ambient occlusion ([#611](https://github.com/reearth/reearth/pull/611)) [`15bd99`](https://github.com/reearth/reearth/commit/15bd99)
- Gpx parsing not working ([#590](https://github.com/reearth/reearth/pull/590)) [`35d6da`](https://github.com/reearth/reearth/commit/35d6da)
- Build ci failling [`54354b`](https://github.com/reearth/reearth/commit/54354b)
- Create workspace beta modal design ([#597](https://github.com/reearth/reearth/pull/597)) [`141026`](https://github.com/reearth/reearth/commit/141026)
- Performance issue when generate md5 with large data.url ([#587](https://github.com/reearth/reearth/pull/587)) [`733862`](https://github.com/reearth/reearth/commit/733862)
- AO invariant error [`b1875e`](https://github.com/reearth/reearth/commit/b1875e)
- Ambient occlusion ([#574](https://github.com/reearth/reearth/pull/574)) [`9ae1af`](https://github.com/reearth/reearth/commit/9ae1af)

#### ✨ Refactor

- Config ([#575](https://github.com/reearth/reearth/pull/575)) [`2ebdf5`](https://github.com/reearth/reearth/commit/2ebdf5)
- Services/api [`4ec0bc`](https://github.com/reearth/reearth/commit/4ec0bc)

#### Miscellaneous Tasks

- Update hexadecimal colors ([#618](https://github.com/reearth/reearth/pull/618)) [`ac2bb9`](https://github.com/reearth/reearth/commit/ac2bb9)
- Version bump to 0.18.0 [`9c794d`](https://github.com/reearth/reearth/commit/9c794d)
- Fix several issues around visualizer render ([#612](https://github.com/reearth/reearth/pull/612)) [`62d28e`](https://github.com/reearth/reearth/commit/62d28e)
- Update button beta design ([#613](https://github.com/reearth/reearth/pull/613)) [`ed4e33`](https://github.com/reearth/reearth/commit/ed4e33)
- Basic publish tab in beta ([#606](https://github.com/reearth/reearth/pull/606)) [`5f3141`](https://github.com/reearth/reearth/commit/5f3141)
- Hook up with story page API ([#592](https://github.com/reearth/reearth/pull/592)) [`9eea0f`](https://github.com/reearth/reearth/commit/9eea0f)
- Add widget and align system update functionality ([#604](https://github.com/reearth/reearth/pull/604)) [`0738b7`](https://github.com/reearth/reearth/commit/0738b7)
- Update widget tab ([#598](https://github.com/reearth/reearth/pull/598)) [`a40c94`](https://github.com/reearth/reearth/commit/a40c94)
- Enable visualizer explicit rendering ([#583](https://github.com/reearth/reearth/pull/583)) [`7a2503`](https://github.com/reearth/reearth/commit/7a2503)
- Unsafe plugin support ([#576](https://github.com/reearth/reearth/pull/576)) [`1ebef7`](https://github.com/reearth/reearth/commit/1ebef7)
- Add list style common DnD component ([#585](https://github.com/reearth/reearth/pull/585)) [`ad4ae6`](https://github.com/reearth/reearth/commit/ad4ae6)
- Add popover contents to left panel and related modification ([#581](https://github.com/reearth/reearth/pull/581)) [`ca753c`](https://github.com/reearth/reearth/commit/ca753c)
- Basic widget page ([#578](https://github.com/reearth/reearth/pull/578)) [`3e8dc0`](https://github.com/reearth/reearth/commit/3e8dc0)
- Add popover and basic content components ([#580](https://github.com/reearth/reearth/pull/580)) [`53bf82`](https://github.com/reearth/reearth/commit/53bf82)
- Panel resize functionality improvements ([#572](https://github.com/reearth/reearth/pull/572)) [`99f5ad`](https://github.com/reearth/reearth/commit/99f5ad)
- Add image-based lighting ([#519](https://github.com/reearth/reearth/pull/519)) [`7622d7`](https://github.com/reearth/reearth/commit/7622d7)
- Add storytelling static content of left panel ([#565](https://github.com/reearth/reearth/pull/565)) [`65c1a1`](https://github.com/reearth/reearth/commit/65c1a1)

### Server

#### 🚀 Features

- Storytelling blocks CRUD ([#610](https://github.com/reearth/reearth/pull/610)) [`5ac70f`](https://github.com/reearth/reearth/commit/5ac70f)
- Support storytelling ([#553](https://github.com/reearth/reearth/pull/553)) [`f9b310`](https://github.com/reearth/reearth/commit/f9b310)
- Extension system ([#584](https://github.com/reearth/reearth/pull/584)) [`847db6`](https://github.com/reearth/reearth/commit/847db6)

#### 🔧 Bug Fixes

- Add missing plugin extensions types ([#624](https://github.com/reearth/reearth/pull/624)) [`b98084`](https://github.com/reearth/reearth/commit/b98084)
- Add missing fields to PropertySchema documents. ([#621](https://github.com/reearth/reearth/pull/621)) [`827c0d`](https://github.com/reearth/reearth/commit/827c0d)

#### ⚡️ Performance

- Add group.linkeddatasetschema index ([#563](https://github.com/reearth/reearth/pull/563)) [`c4f2c1`](https://github.com/reearth/reearth/commit/c4f2c1)
- Improve dataset index ([#562](https://github.com/reearth/reearth/pull/562)) [`49ce87`](https://github.com/reearth/reearth/commit/49ce87)

#### Miscellaneous Tasks

- Revert changes on ci_server.yml [`fb45e0`](https://github.com/reearth/reearth/commit/fb45e0)
- Expand sys extensions to support storytelling pages/blocks ([#622](https://github.com/reearth/reearth/pull/622)) [`c4c46c`](https://github.com/reearth/reearth/commit/c4c46c)
- Add JSON schema to built in manifest ([#617](https://github.com/reearth/reearth/pull/617)) [`755931`](https://github.com/reearth/reearth/commit/755931)
- Add spacing value type with padding and margin UI support ([#616](https://github.com/reearth/reearth/pull/616)) [`99abf5`](https://github.com/reearth/reearth/commit/99abf5)

### Misc

#### Miscellaneous Tasks

- Revert CHANGELOG.md to same as main [`ac3594`](https://github.com/reearth/reearth/commit/ac3594)
- Remove prev CHANGELOG changes [`c248fc`](https://github.com/reearth/reearth/commit/c248fc)
- Update reviewer-lottery.yml [`79aaf0`](https://github.com/reearth/reearth/commit/79aaf0)
- Update theme&[#39](https://github.com/reearth/reearth/pull/39);s colors ([#589](https://github.com/reearth/reearth/pull/589)) [`714fb9`](https://github.com/reearth/reearth/commit/714fb9)
- Update CODEOWNERS [`0b8919`](https://github.com/reearth/reearth/commit/0b8919)

###

#### Miscellaneous Tasks

- Revert CHANGELOG.md to same as main [`ac3594`](https://github.com/reearth/reearth/commit/ac3594)
- Remove prev CHANGELOG changes [`c248fc`](https://github.com/reearth/reearth/commit/c248fc)
- Update reviewer-lottery.yml [`79aaf0`](https://github.com/reearth/reearth/commit/79aaf0)
- Update theme&[#39](https://github.com/reearth/reearth/pull/39);s colors ([#589](https://github.com/reearth/reearth/pull/589)) [`714fb9`](https://github.com/reearth/reearth/commit/714fb9)
- Update CODEOWNERS [`0b8919`](https://github.com/reearth/reearth/commit/0b8919)

## 0.17.0 - 2023-07-11

### Web
Expand Down
4 changes: 4 additions & 0 deletions server/gql/plugin.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ enum PluginExtensionType {
BLOCK
VISUALIZER
INFOBOX
Cluster
Story
StoryPage
StoryBlock
}

type PluginExtension {
Expand Down
4 changes: 4 additions & 0 deletions server/internal/adapter/gql/generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions server/internal/adapter/gql/gqlmodel/convert_plugin.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,14 @@ func ToPluginExtensionType(t plugin.ExtensionType) PluginExtensionType {
return PluginExtensionTypeVisualizer
case plugin.ExtensionTypeInfobox:
return PluginExtensionTypeInfobox
case plugin.ExtensionTypeCluster:
return PluginExtensionTypeCluster
case plugin.ExtensionTypeStory:
return PluginExtensionTypeStory
case plugin.ExtensionTypeStoryPage:
return PluginExtensionTypeStoryPage
case plugin.ExtensionTypeStoryBlock:
return PluginExtensionTypeStoryBlock
}
return PluginExtensionType("")
}
Expand Down
10 changes: 9 additions & 1 deletion server/internal/adapter/gql/gqlmodel/models_gen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 3 additions & 4 deletions web/src/beta/components/ListItem/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,17 +71,16 @@ const Inner = styled.button<{ border?: boolean; isSelected?: boolean; clamp?: Cl
width: 100%;
min-height: 38px;
align-items: center;
border: 1px solid ${({ border }) => (border ? "#383838" : "transparent")};
border: 1px solid ${({ border, theme }) => (border ? theme.outline.weakest : "transparent")};
border-radius: ${({ clamp }) =>
clamp === "left" ? "0 6px 6px 0" : clamp === "right" ? "6px 0 0 6px" : "6px"};
box-sizing: border-box;
padding: 8px 20px 8px 4px;
background: ${({ theme, isSelected }) => (isSelected ? theme.select.main : "inherit")};
transition: all 0.3s;
${({ isSelected }) => isSelected && `background-color: #3B3CD0;`}
:hover {
${({ isSelected }) => !isSelected && `background-color: #232226;`}
${({ isSelected, theme }) => !isSelected && `background-color:` + theme.bg[3]}
}
`;

Expand All @@ -100,7 +99,7 @@ const Button = styled.button<{ clamp?: Clamp }>`
transform: translateY(-50%);
padding: 4px;
margin-left: -1px;
color: #4a4a4a;
color: ${({ theme }) => theme.content.weak};
border-radius: ${({ clamp }) =>
clamp === "left" ? "0 6px 6px 0" : clamp === "right" ? "6px 0 0 6px" : "6px"};
Expand Down
2 changes: 1 addition & 1 deletion web/src/beta/components/PopoverMenuContent/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ const SRoot = styled.div<Pick<Props, "width">>`
border-radius: 2px;
border: 1px solid ${({ theme }) => theme.bg[3]};
background: #262626;
background: ${({ theme }) => theme.bg[1]};
box-shadow: 4px 4px 4px 0px rgba(0, 0, 0, 0.25);
`;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ const Wrapper = styled.div<{ widthPercentage: number }>`
content: "";
position: absolute;
inset: 0;
background-color: #3592ff;
background-color: ${({ theme }) => theme.select.main};
transition: width 0.2s ease-out;
width: ${({ widthPercentage }) => widthPercentage}%;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const Wrapper = styled.button`
min-height: 28px;
transition: all 0.15s;
border: 1px solid #383838;
border: 1px solid ${({ theme }) => theme.outline.weakest};
:hover {
background: ${props => props.theme.bg[3]};
Expand All @@ -52,7 +52,7 @@ const IconWrapper = styled.div`
display: flex;
align-items: center;
justify-content: center;
color: #4a4a4a;
color: ${({ theme }) => theme.content.weak};
`;

export default StorySidePanelAction;
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { FC, ReactNode } from "react";

import Icon from "@reearth/beta/components/Icon";
import Text from "@reearth/beta/components/Text";
import { styled } from "@reearth/services/theme";
import { styled, useTheme } from "@reearth/services/theme";

type Props = {
children: ReactNode;
Expand All @@ -11,14 +11,16 @@ type Props = {
};

const StorySidePanelPageWrapper: FC<Props> = ({ children, pageCount, isSwipeable }) => {
const theme = useTheme();

return (
<Wrapper>
<Left>
<div>
<Text size="footnote">{pageCount}</Text>
</div>
<div>
<Icon icon={isSwipeable ? "swiper" : "square"} color="#4A4A4A" size={12} />
<Icon icon={isSwipeable ? "swiper" : "square"} color={theme.content.weak} size={12} />
</div>
</Left>
<Right>{children}</Right>
Expand Down
10 changes: 5 additions & 5 deletions web/src/beta/features/Modals/WorkspaceCreationModal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ export interface FormValues {
// description: string;
}

export interface Props {
export type Props = {
open?: boolean;
onClose?: (refetch?: boolean) => void;
onSubmit?: (values: FormValues) => Promise<void> | void;
}
};

const initialValues: FormValues = {
name: "",
Expand Down Expand Up @@ -97,10 +97,10 @@ const FormInputWrapper = styled.div`

const StyledInput = styled.input`
flex: 2;
color: ${props => props.theme.content.main};
background: ${props => props.theme.bg[0]};
color: ${({ theme }) => theme.content.main};
background: ${({ theme }) => theme.bg[0]};
border-radius: 4px;
border: 1px solid #3f3d45;
border: 1px solid ${({ theme }) => theme.bg[4]};
font-size: ${fonts.sizes.body}px;
cursor: text;
padding: 4px 8px;
Expand Down
19 changes: 7 additions & 12 deletions web/src/beta/lib/core/Crust/Infobox/Block/builtin/unsafeBlocks.ts
Original file line number Diff line number Diff line change
@@ -1,25 +1,20 @@
import { merge } from "lodash-es";

import { config } from "@reearth/services/config";
import { type UnsafeBuiltinPlugin } from "@reearth/services/config/unsafeBuiltinPlugin";

import { Component } from "..";
import { UnsafeBuiltinPlugin } from "../../../types";

export type UnsafeBuiltinBlocks<T = unknown> = Record<string, T>;

let unsafeBuiltinPlugins;

(async () => {
unsafeBuiltinPlugins = (await import(/* @vite-ignore */ "src/beta/lib/unsafeBuiltinPlugins"))
.default;
})();

export const unsafeBuiltinBlocks = processUnsafeBuiltinBlocks(unsafeBuiltinPlugins);
export const unsafeBuiltinBlocks = processUnsafeBuiltinBlocks(config()?.unsafeBuiltinPlugins);

function processUnsafeBuiltinBlocks(plugin?: UnsafeBuiltinPlugin[]) {
if (!plugin) return;

const unsafeBlocks: UnsafeBuiltinBlocks<Component> | undefined = plugin
.map(p =>
p.widgets.map(w => {
p.blocks?.map(w => {
return {
widgetId: `${p.id}/${w.extensionId}`,
...w,
Expand All @@ -28,11 +23,11 @@ function processUnsafeBuiltinBlocks(plugin?: UnsafeBuiltinPlugin[]) {
)
.reduce((a, b) => {
const newObject: { [key: string]: Component } = {};
b.forEach(w => {
b?.forEach(w => {
newObject[w.widgetId] = w.component;
});
return merge(a, newObject);
}, {});

return unsafeBlocks;
return unsafeBlocks || [];
}
Original file line number Diff line number Diff line change
@@ -1,27 +1,22 @@
import { merge } from "lodash-es";

import { config } from "@reearth/services/config";
import { type UnsafeBuiltinPlugin } from "@reearth/services/config/unsafeBuiltinPlugin";

import type { Component } from "..";
import { UnsafeBuiltinPlugin } from "../../../types";

export type { Component } from "..";

export type UnsafeBuiltinWidgets<T = unknown> = Record<string, T>;

let unsafeBuiltinPlugins;

(async () => {
unsafeBuiltinPlugins = (await import(/* @vite-ignore */ "src/beta/lib/unsafeBuiltinPlugins"))
.default;
})();

export const unsafeBuiltinWidgets = processUnsafeBuiltinWidgets(unsafeBuiltinPlugins);
export const unsafeBuiltinWidgets = processUnsafeBuiltinWidgets(config()?.unsafeBuiltinPlugins);

function processUnsafeBuiltinWidgets(plugin?: UnsafeBuiltinPlugin[]) {
if (!plugin) return;

const unsafeWidgets: UnsafeBuiltinWidgets<Component> | undefined = plugin
.map(p =>
p.widgets.map(w => {
p.widgets?.map(w => {
return {
widgetId: `${p.id}/${w.extensionId}`,
...w,
Expand All @@ -30,11 +25,11 @@ function processUnsafeBuiltinWidgets(plugin?: UnsafeBuiltinPlugin[]) {
)
.reduce((a, b) => {
const newObject: { [key: string]: Component } = {};
b.forEach(w => {
b?.forEach(w => {
newObject[w.widgetId] = w.component;
});
return merge(a, newObject);
}, {});

return unsafeWidgets;
return unsafeWidgets || [];
}
Loading

0 comments on commit 14645d1

Please sign in to comment.