Skip to content
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

experimental rc ui #894

Draft
wants to merge 38 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
838dbdc
wire up RC emulator
jhuleatt Nov 2, 2021
20ccc8c
lint
jhuleatt Nov 2, 2021
9989350
add RC to emulator types
jhuleatt Nov 2, 2021
3f8d38f
fetch and modify rc templates
jhuleatt Nov 2, 2021
1052c86
tiny bit of styling
jhuleatt Nov 2, 2021
9193bad
style the button
jhuleatt Nov 2, 2021
387befb
Fixes remote config UI deploys
abeisgoat Nov 4, 2021
ddde6d0
initial param table prototype
jhuleatt Dec 3, 2021
f70b5b5
lint
jhuleatt Dec 3, 2021
d926a3f
"filter" -> "search"
jhuleatt Dec 9, 2021
149e2a2
selecting a value actually updates emulator
jhuleatt Dec 9, 2021
355b4d2
add an edit component
jhuleatt Mar 14, 2022
add6722
add edit buttons to param list
jhuleatt Mar 14, 2022
5649418
search by param name, value, conditions
jhuleatt Mar 14, 2022
512aba1
only allow value type values to be edited
jhuleatt Mar 14, 2022
bfd2676
styling
jhuleatt Mar 14, 2022
b9b4270
remove debugging artifact
jhuleatt Mar 14, 2022
c6c9e9d
first attempt at column header
jhuleatt Mar 18, 2022
bef8b86
lint
jhuleatt Mar 18, 2022
90c0f6c
add a reset button
jhuleatt Mar 18, 2022
9435e85
UI refinement
jhuleatt Mar 21, 2022
835168f
support tag colors
jhuleatt Jun 30, 2022
e284ba1
single-word remoteconfig
jhuleatt Jul 20, 2022
0954ccb
add rmwc chip
jhuleatt Jul 20, 2022
636b61d
break out into different files
jhuleatt Nov 11, 2022
1a3d434
feat: add bulk update (#891)
HYACCCINT Dec 13, 2022
d5c8202
set a version for bug bash
jhuleatt Dec 21, 2022
59ab257
match the color scheme set in the console
jhuleatt Jan 13, 2023
6259668
update after reset
HYACCCINT Dec 21, 2022
9b8e727
Revert "update after reset"
HYACCCINT Dec 21, 2022
0b603fd
feat: add rc emulator disabled fallback (#904)
HYACCCINT Jan 12, 2023
f79cbe4
RC dialog update (#909)
HYACCCINT Jan 13, 2023
7a16878
update edit dialog text to match UX guidance
jhuleatt Jan 13, 2023
11f0232
fix classnames for condition colors
jhuleatt Jan 13, 2023
f9627e8
set the alpha channel for condition colors
jhuleatt Jan 13, 2023
926cb50
Clarify edit UX for in-app defaults (#911)
jhuleatt Jan 19, 2023
30cb506
fix: updating rc template should reflect on emulator (#915)
HYACCCINT Feb 3, 2023
b8971e8
update version
jhuleatt Feb 9, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions firebase.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,16 @@
},
"pubsub": {
"port": 8085
},
"remoteconfig": {
"port": 9200
}
},
"extensions": {
"storage-resize-images": "firebase/[email protected]",
"firestore-stripe-payments": "stripe/[email protected]"
},
"remoteconfig": {
"template": "remoteconfig.template.json"
}
}
83 changes: 83 additions & 0 deletions package-lock.json

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

4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "firebase-tools-ui",
"version": "1.11.7",
"version": "1.11.1-rc-bash",
"private": true,
"engines": {
"node": ">=16.4.0"
Expand All @@ -10,6 +10,7 @@
"@rmwc/button": "^7.0.3",
"@rmwc/card": "^7.0.3",
"@rmwc/checkbox": "^7.0.3",
"@rmwc/chip": "^7.0.3",
"@rmwc/circular-progress": "^7.0.3",
"@rmwc/data-table": "^7.0.3",
"@rmwc/dialog": "^7.0.3",
Expand Down Expand Up @@ -122,6 +123,7 @@
"eslint-plugin-jest": "^23.11.0",
"eslint-plugin-react-hooks": "^4.0.0",
"eslint-plugin-unused-imports": "^2.0.0",
"firebase-admin": "^10.0.0",
"globalthis": "^1.0.1",
"husky": "^8.0.0",
"import-sort-config": "^6.0.0",
Expand Down
40 changes: 40 additions & 0 deletions remoteconfig.template.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"conditions": [
{
"name": "iOS",
"expression": "device.os == 'ios'",
"tagColor": "LIME"
}
],
"parameters": {
"welcome_message": {
"defaultValue": {
"value": "Welcome to this sample app"
},
"conditionalValues": {
"iOS": {
"value": "Welcome to this sample iOS app"
}
}
},
"welcome_message_caps": {
"defaultValue": {
"value": "false"
}
},
"header_text": {
"defaultValue": {
"useInAppDefault": true
}
}
},
"version": {
"versionNumber": "28",
"updateTime": "2020-05-14T18:39:38.994Z",
"updateUser": {
"email": "[email protected]"
},
"updateOrigin": "CONSOLE",
"updateType": "INCREMENTAL_UPDATE"
}
}
8 changes: 8 additions & 0 deletions src/components/Home/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ import {
FunctionsIcon,
HostingIcon,
PubSubIcon,
RemoteConfigIcon,
StorageIcon,
} from '../common/icons';
import { Spinner } from '../common/Spinner';
Expand Down Expand Up @@ -94,6 +95,13 @@ const Overview: React.FC<
linkLabel="Go to database emulator"
testId="emulator-info-database"
/>
<EmulatorCard
name="Remote Config emulator"
icon={<RemoteConfigIcon theme="secondary" />}
config={config['remoteconfig']}
linkTo="/remote-config"
testId="emulator-info-remote-config"
/>
<EmulatorCard
name="Functions emulator"
icon={<FunctionsIcon theme="secondary" />}
Expand Down
26 changes: 26 additions & 0 deletions src/components/RemoteConfig/AdvancedEditCard.module.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
/**
* Copyright 2020 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance
the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@import '../common/color';

.wrapper {
align-items: center;
display: flex;
flex-direction: row;
justify-content: space-between;
margin-top: 20px;
padding: 32px 24px;
}
49 changes: 49 additions & 0 deletions src/components/RemoteConfig/AdvancedEditCard.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
/**
* Copyright 2021 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

import { Card } from '@rmwc/card';
import { Typography } from '@rmwc/typography';
import React from 'react';

import styles from './AdvancedEditCard.module.scss';

export const AdvancedEditCard: React.FC<{}> = () => {
return (
<Card className={styles.wrapper}>
<div>
<Typography use="headline6" tag="div" theme="textPrimaryOnBackground">
Need to make more advanced edits?
</Typography>
<Typography use="body2" theme="textPrimaryOnBackground">
<p>
Edit your local <code>remoteconfig.template.json</code> file in your
favorite code editor to make more in-depth changes to your Remote
Config template, such as modifying in-app default values.
</p>
</Typography>
<Typography use="body2" theme="textPrimaryOnBackground">
<a
target="_blank"
rel="noopener noreferrer"
href="https://firebase.google.com/docs/remote-config/templates"
>
Learn more about Remote Config templates
</a>
</Typography>
</div>
</Card>
);
};
Loading
Loading