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

Release #3183

Merged
merged 10 commits into from
Oct 24, 2024
2 changes: 2 additions & 0 deletions .github/workflows/mobile.apps.android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ jobs:
EXPO_PROJECT_NAME: ${{ secrets.EXPO_PROJECT_NAME }}
EXPO_PROJECT_OWNER: ${{ secrets.EXPO_PROJECT_OWNER }}
EXPO_PROJECT_ID: ${{ secrets.EXPO_PROJECT_ID }}
EXPO_PROJECT_PACKAGE_NAME: ${{ secrets.EXPO_PROJECT_PACKAGE_NAME }}
EXPO_PROJECT_IOS_BUNDLE_IDENTIFIER: ${{ secrets.EXPO_PROJECT_IOS_BUNDLE_IDENTIFIER }}

- name: Build on EAS
run: cd apps/mobile && eas build --platform android --non-interactive
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/mobile.apps.ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ jobs:
EXPO_PROJECT_NAME: ${{ secrets.EXPO_PROJECT_NAME }}
EXPO_PROJECT_OWNER: ${{ secrets.EXPO_PROJECT_OWNER }}
EXPO_PROJECT_ID: ${{ secrets.EXPO_PROJECT_ID }}
EXPO_PROJECT_PACKAGE_NAME: ${{ secrets.EXPO_PROJECT_PACKAGE_NAME }}
EXPO_PROJECT_IOS_BUNDLE_IDENTIFIER: ${{ secrets.EXPO_PROJECT_IOS_BUNDLE_IDENTIFIER }}

- name: Build on EAS
run: cd apps/mobile && eas build --platform ios --non-interactive
Expand Down
4 changes: 3 additions & 1 deletion .scripts/configure.mobile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ fs.copyFile(templatePath, appJsonPath, (err) => {
.replace(/\$EXPO_PROJECT_SLUG/g, process.env.EXPO_PROJECT_SLUG)
.replace(/\$EXPO_PROJECT_NAME/g, process.env.EXPO_PROJECT_NAME)
.replace(/\$EXPO_PROJECT_OWNER/g, process.env.EXPO_PROJECT_OWNER)
.replace(/\$EXPO_PROJECT_ID/g, process.env.EXPO_PROJECT_ID);
.replace(/\$EXPO_PROJECT_ID/g, process.env.EXPO_PROJECT_ID)
.replace(/\$EXPO_PROJECT_PACKAGE_NAME/g, process.env.EXPO_PROJECT_PACKAGE_NAME)
.replace(/\$EXPO_PROJECT_IOS_BUNDLE_IDENTIFIER/g, process.env.EXPO_PROJECT_IOS_BUNDLE_IDENTIFIER);

fs.writeFile(appJsonPath, updatedData, (err) => {
if (err) {
Expand Down
2 changes: 2 additions & 0 deletions apps/mobile/.env
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@ EXPO_PROJECT_SLUG=ever-teams-mobile
EXPO_PROJECT_NAME=Ever Teams Mobile
EXPO_PROJECT_OWNER=everco
EXPO_PROJECT_ID=2ff924e4-7a91-4b23-9db9-7453a8063bb0
EXPO_PROJECT_PACKAGE_NAME=ever.team
EXPO_PROJECT_IOS_BUNDLE_IDENTIFIER=co.ever.teams
4 changes: 2 additions & 2 deletions apps/mobile/app.template.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
],
"android": {
"icon": "./assets/images/app-icon-android-legacy-ever-teams.png",
"package": "ever.team",
"package": "$EXPO_PROJECT_PACKAGE_NAME",
"adaptiveIcon": {
"foregroundImage": "./assets/images/app-icon-android-adaptive-foreground-ever.png",
"backgroundImage": "./assets/images/app-icon-android-adaptive-background.png"
Expand All @@ -63,7 +63,7 @@
"ios": {
"icon": "./assets/images/app-icon-ios-ever-teams.png",
"supportsTablet": true,
"bundleIdentifier": "co.ever.teams",
"bundleIdentifier": "$EXPO_PROJECT_IOS_BUNDLE_IDENTIFIER",
"splash": {
"image": "./assets/images/splash-ever-teams.png",
"tabletImage": "./assets/images/splash-logo-ever-teams-ios-tablet.png",
Expand Down
70 changes: 19 additions & 51 deletions apps/mobile/eas.json
Original file line number Diff line number Diff line change
@@ -1,53 +1,21 @@
{
"cli": {
"appVersionSource": "remote"
},
"build": {
"development": {
"extends": "production",
"developmentClient": true,
"distribution": "internal",
"ios": {
"simulator": true
},
"android": {
"buildType": "apk"
},
"channel": "development"
},
"preview": {
"extends": "production",
"distribution": "internal",
"channel": "preview",
"ios": {
"simulator": true
},
"android": {
"buildType": "apk"
}
},
"production": {
"autoIncrement": true,
"channel": "production",
"env": {
"GAUZY_API_URL": "https://api.ever.team",
"INVITE_CALLBACK_URL": "https://app.ever.team/auth/passcode"
}
}
},
"submit": {
"production": {
"android": {
"track": "internal",
"releaseStatus": "draft",
"changesNotSentForReview": false
},
"ios": {
"ascAppId": "APPLE_ID_PLACEHOLDER",
"ascApiKeyIssuerId": "APPSTORE_ISSUER_ID_PLACEHOLDER",
"ascApiKeyId": "APPSTORE_API_KEY_ID_PLACEHOLDER",
"ascApiKeyPath": "./AuthKey_R9QZ5LP8NK.p8"
}
}
}
"cli": {
"version": ">= 12.5.3",
"appVersionSource": "remote"
},
"build": {
"development": {
"developmentClient": true,
"distribution": "internal"
},
"preview": {
"distribution": "internal"
},
"production": {
"autoIncrement": true
}
},
"submit": {
"production": {}
}
}
1 change: 1 addition & 0 deletions apps/mobile/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
"apisauce": "3.0.0",
"axios": "^1.6.0",
"date-fns": "^2.29.2",
"eas": "^0.1.0",
"expo": "~48.0.9",
"expo-application": "~5.1.1",
"expo-blur": "~12.2.2",
Expand Down
5 changes: 5 additions & 0 deletions apps/mobile/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5924,6 +5924,11 @@ duplexify@^3.4.2, duplexify@^3.6.0:
readable-stream "^2.0.0"
stream-shift "^1.0.0"

eas@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/eas/-/eas-0.1.0.tgz#cc3c1d8f1aa9439a873670440cf946af1c5707b4"
integrity sha512-w88fTTTkfDLHwcaVW8wiYjOtnBBToguzc6AyIldD1vOrCRTKxhQEDS8oIE7nWeSJ+kCoIeoHd79Mhwvntydixg==

easy-stack@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/easy-stack/-/easy-stack-1.0.1.tgz#8afe4264626988cabb11f3c704ccd0c835411066"
Expand Down
2 changes: 1 addition & 1 deletion apps/web/app/hooks/features/useStartStopTimerHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ export function useStartStopTimerHandler() {
if (timerStatusFetching || !canRunTimer) return;
if (timerStatus?.running) {
stopTimer();
} else if (requirePlan && !isActiveTaskPlaned) {
} else if (requirePlan && hasPlan && !isActiveTaskPlaned) {
openEnforcePlannedTaskModal();
} else {
if (
Expand Down
4 changes: 1 addition & 3 deletions apps/web/app/hooks/features/useTimer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -265,9 +265,7 @@ export function useTimer() {
user?.isEmailVerified &&
((!!activeTeamTask && activeTeamTask.status !== 'closed') ||
// If timer is running at some other source and user may or may not have selected the task
timerStatusRef.current?.lastLog?.source !== TimerSource.TEAMS) &&
// If team settings require to have a plan to be able track
canTrack;
timerStatusRef.current?.lastLog?.source !== TimerSource.TEAMS)

// Local time status
const {
Expand Down
54 changes: 30 additions & 24 deletions apps/web/lib/components/modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ type Props = {
className?: string;
alignCloseIcon?: boolean;
showCloseIcon?: boolean;
closeOnOutsideClick?: boolean;
} & PropsWithChildren;

export function Modal({
Expand All @@ -27,7 +28,8 @@ export function Modal({
description,
className,
alignCloseIcon,
showCloseIcon = true
showCloseIcon = true,
closeOnOutsideClick = false
}: Props) {
const refDiv = useRef(null);

Expand All @@ -44,36 +46,40 @@ export function Modal({
>
<Dialog
initialFocus={refDiv}
onClose={closeModal}
onClose={closeOnOutsideClick ? closeModal : () => null}
as="div"
className="fixed inset-0 backdrop-brightness-90 backdrop-blur-sm z-[9999] w-full h-full"
>
<div ref={refDiv} className="absolute inset-0 flex items-center justify-center p-4 w-full">
<Dialog.Overlay
className={clsxm('flex justify-center items-center flex-col space-y-1 relative', className)}
>
{title && <Dialog.Title className={clsxm(titleClass)}>{title}</Dialog.Title>}
{description && <Dialog.Description>{description}</Dialog.Description>}
{showCloseIcon && (
<div
onClick={() => {
closeModal();
customCloseModal?.();
}}
className={`absolute ${
alignCloseIcon ? 'right-2 top-3' : 'right-3 top-3'
} md:right-2 md:top-3 cursor-pointer z-50`}
>
<Image
src={'/assets/svg/close.svg'}
alt="close"
width={28}
height={28}
className="w-6 md:w-7"
/>
</div>
)}
{children}
<Dialog.Panel
className={clsxm('flex justify-center items-center flex-col space-y-1 relative', className)}
>
{title && <Dialog.Title className={clsxm(titleClass)}>{title}</Dialog.Title>}
{description && <Dialog.Description>{description}</Dialog.Description>}
{showCloseIcon && (
<div
onClick={() => {
closeModal();
customCloseModal?.();
}}
className={`absolute ${
alignCloseIcon ? 'right-2 top-3' : 'right-3 top-3'
} md:right-2 md:top-3 cursor-pointer z-50`}
>
<Image
src={'/assets/svg/close.svg'}
alt="close"
width={28}
height={28}
className="w-6 md:w-7"
/>
</div>
)}
{children}
</Dialog.Panel>
</Dialog.Overlay>
</div>
</Dialog>
Expand Down
4 changes: 4 additions & 0 deletions apps/web/lib/components/switch.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { Switch } from '@headlessui/react';
import { useCallback, useEffect, useState } from 'react';
import { Text } from './typography';
import { useTranslations } from 'next-intl';
import { DAILY_PLAN_SUGGESTION_MODAL_DATE } from '@app/constants';

export default function TimeTrackingToggle({ activeManager }: { activeManager: OT_Member | undefined }) {
const t = useTranslations();
Expand Down Expand Up @@ -129,6 +130,9 @@ export function RequireDailyPlanToTrack() {
.filter((value, index, array) => array.indexOf(value) === index)
});
setEnabled(!enabled);
if (!enabled) {
localStorage.removeItem(DAILY_PLAN_SUGGESTION_MODAL_DATE);
}
}
}, [activeTeam, editOrganizationTeam, enabled]);

Expand Down
96 changes: 44 additions & 52 deletions apps/web/lib/features/auth-user-task-input.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,63 +7,55 @@ import { useAtomValue } from 'jotai';
import { TaskEstimate } from './task/task-estimate';
import { TaskInput } from './task/task-input';
import { TaskLabels } from './task/task-labels';
import {
ActiveTaskPropertiesDropdown,
ActiveTaskSizesDropdown,
ActiveTaskStatusDropdown
} from './task/task-status';
import { ActiveTaskPropertiesDropdown, ActiveTaskSizesDropdown, ActiveTaskStatusDropdown } from './task/task-status';
import { useTranslations } from 'next-intl';

export function AuthUserTaskInput({ className }: IClassName) {
const t = useTranslations();
const activeTeamTask = useAtomValue(activeTeamTaskState);
const { isTrackingEnabled } = useOrganizationTeams();
const t = useTranslations();
const activeTeamTask = useAtomValue(activeTeamTaskState);
const { isTrackingEnabled } = useOrganizationTeams();

return (
<div
className={clsxm('flex-1 flex flex-col mr-10 lg:mt-0 mt-8', className)}
>
<TaskInput
fullWidthCombobox={true}
createOnEnterClick={true}
showTaskNumber={true}
autoAssignTaskAuth={isTrackingEnabled}
/>
<div className="flex gap-5 flex-row lg:items-center justify-between ml-2">
<div className="xl:flex mb-4 lg:mb-0">
<span className="font-normal text-gray-500 pr-2">
{t('common.ESTIMATE')}:
</span>
<TaskEstimate />
</div>
return (
<div className={clsxm('flex-1 flex flex-col mr-10 lg:mt-0 mt-8', className)}>
<TaskInput
fullWidthCombobox={true}
createOnEnterClick={true}
showTaskNumber={true}
autoAssignTaskAuth={isTrackingEnabled}
/>
<div className="flex gap-5 flex-row lg:items-center justify-between ml-2">
<div className="xl:flex mb-4 lg:mb-0">
<span className="font-normal text-gray-500 pr-2">{t('common.ESTIMATE')}:</span>
<TaskEstimate />
</div>

<div className="flex-grow justify-end hidden flex-1 gap-2 md:flex">
<ActiveTaskStatusDropdown
className="lg:max-w-[190px] w-full"
disabled={!activeTeamTask}
taskStatusClassName="text-xs py-1.5 w-full"
/>
<div className="flex-grow justify-end hidden flex-1 gap-2 md:flex">
<ActiveTaskStatusDropdown
className="lg:max-w-[190px] w-full"
disabled={!activeTeamTask}
taskStatusClassName="text-xs py-1.5 w-full"
/>

<ActiveTaskPropertiesDropdown
className="lg:max-w-[190px] w-full"
disabled={!activeTeamTask}
taskStatusClassName="w-full py-1.5 text-xs"
/>
<ActiveTaskPropertiesDropdown
className="lg:max-w-[190px] w-full"
disabled={!activeTeamTask}
taskStatusClassName="w-full py-1.5 text-xs"
/>

<ActiveTaskSizesDropdown
className="lg:max-w-[190px] w-full"
disabled={!activeTeamTask}
taskStatusClassName="w-full py-1.5 text-xs"
/>
<ActiveTaskSizesDropdown
className="lg:max-w-[190px] w-full"
disabled={!activeTeamTask}
taskStatusClassName="w-full py-1.5 text-xs"
/>

<TaskLabels
task={activeTeamTask}
className="lg:max-w-[170px] w-full text-xs"
forDetails={false}
taskStatusClassName="dark:bg-[#1B1D22] dark:border py-[7px] dark:border-[#FFFFFF33] text-xs"
/>
</div>
{/* <div className="grid justify-items-center md:hidden">
<TaskLabels
task={activeTeamTask}
className="lg:max-w-[170px] w-full text-xs"
forDetails={false}
taskStatusClassName="dark:bg-[#1B1D22] dark:border py-[7px] dark:border-[#FFFFFF33] text-xs"
/>
</div>
{/* <div className="grid justify-items-center md:hidden">
<div className="flex">
<ActiveTaskStatusDropdown className="w-32 mr-2" disabled={!activeTeamTask} />
<ActiveTaskPropertiesDropdown className="w-32" disabled={!activeTeamTask} />
Expand All @@ -73,7 +65,7 @@ export function AuthUserTaskInput({ className }: IClassName) {
<TaskLabels task={activeTeamTask} className="lg:min-w-[170px]" forDetails={false} />
</div>
</div> */}
</div>
</div>
);
</div>
</div>
);
}
Loading
Loading