Coder Social home page Coder Social logo

Comments (16)

kevcjones-archived avatar kevcjones-archived commented on August 14, 2024

Could you dump the output for ng -v on your command line for me so I can try to recreate your environment?

Thanks

from ngx-simple-modal.

kevcjones-archived avatar kevcjones-archived commented on August 14, 2024
    _                      _                 ____ _     ___
   / \   _ __   __ _ _   _| | __ _ _ __     / ___| |   |_ _|
  / △ \ | '_ \ / _` | | | | |/ _` | '__|   | |   | |    | |
 / ___ \| | | | (_| | |_| | | (_| | |      | |___| |___ | |
/_/   \_\_| |_|\__, |\__,_|_|\__,_|_|       \____|_____|___|
               |___/

Angular CLI: 1.7.3
Node: 9.6.1
OS: linux x64
Angular: 5.2.9
... animations, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router

@angular/cli: 1.7.3
@angular-devkit/build-optimizer: 0.3.2
@angular-devkit/core: 0.3.2
@angular-devkit/schematics: 0.3.2
@ngtools/json-schema: 1.2.0
@ngtools/webpack: 1.10.2
@schematics/angular: 0.3.2
@schematics/package-update: 0.3.2
typescript: 2.4.2
webpack: 3.11.0

Working on my machine 🤕 but was back when the latest was 5.2x.

cd demo
npm i
ng serve

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

Hi.thanks for your answer
ng -v :

@angular/cli: 1.7.4
@angular-devkit/build-optimizer: 0.3.2
@angular-devkit/core: 0.3.2
@angular-devkit/schematics: 0.3.2
@ngtools/json-schema: 1.2.0
@ngtools/webpack: 1.10.2
@schematics/angular: 0.3.2
@schematics/package-update: 0.3.2
typescript: 2.4.2
webpack: 3.11.0

I've updated angular CLI with npm install -g @angular/cli@latest

now got error after ng serve:

ERROR in multi ./src/styles.css ./node_modules/ngx-simple-modal/styles/simple-modal.css
Module not found: Error: Can't resolve 'c:\aa\2\ngx-simple-modal-master\demo\node_modules\ngx-simple-modal\styles\simple-modal.css' in 'c:\aa\2\ngx-simple-modal-master\demo'
ERROR in src/app/alert-select/alert-select.component.ts(2,38): error TS2307: Cannot find module 'ngx-simple-modal'.
src/app/alert/alert.component.ts(2,38): error TS2307: Cannot find module 'ngx-simple-modal'.
src/app/app.component.ts(3,36): error TS2307: Cannot find module 'ngx-simple-modal'.
src/app/app.module.ts(5,55): error TS2307: Cannot find module 'ngx-simple-modal'.
src/app/app.module.ts(17,75): error TS2307: Cannot find module 'ngx-simple-modal/simple-modal/simple-modal-options'.
src/app/confirm/confirm.component.ts(2,38): error TS2307: Cannot find module 'ngx-simple-modal'.
src/app/confirm/confirm.component.ts(35,10): error TS2339: Property 'result' does not exist on type 'ConfirmComponent'.
src/app/confirm/confirm.component.ts(36,10): error TS2339: Property 'close' does not exist on type 'ConfirmComponent'.
src/app/confirm/confirm.component.ts(39,10): error TS2339: Property 'result' does not exist on type 'ConfirmComponent'.
src/app/confirm/confirm.component.ts(40,10): error TS2339: Property 'close' does not exist on type 'ConfirmComponent'.
src/app/custom-error/custom-error-handler.ts(2,36): error TS2307: Cannot find module 'ngx-simple-modal'.
src/app/parent-dialog/parent-dialog.component.ts(2,58): error TS2307: Cannot find module 'ngx-simple-modal'.
src/app/parent-dialog/parent-dialog.component.ts(37,14): error TS2339: Property 'close' does not exist on type 'ParentDialogModalComponent'.
src/app/prompt/prompt.component.ts(2,38): error TS2307: Cannot find module 'ngx-simple-modal'.
src/app/prompt/prompt.component.ts(35,10): error TS2339: Property 'result' does not exist on type 'PromptComponent'.
src/app/prompt/prompt.component.ts(36,10): error TS2339: Property 'close' does not exist on type 'PromptComponent'.


from ngx-simple-modal.

kevcjones-archived avatar kevcjones-archived commented on August 14, 2024

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

What about invisible status,I've tried upgrading one project from angularx-bootstrap-modal to ngx-simple-modal but as mention before no error on console but dialog is invisible,I'm sure it exists because after calling this.simpleModalService.addModal I can't focus nothing on the page,there must be invisible.thanks

from ngx-simple-modal.

kevcjones-archived avatar kevcjones-archived commented on August 14, 2024

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

Hi
I've found this class applied to div next to simple-modal-wrapper:

.fade:not(.show) {
    opacity: 0;
}
<div role="dialog" class="modal fade in" ng-reflect-ng-class="modal fade" ng-reflect-ng-style="[object Object]" style="display: block;">
        <!----><confirm>
    <div class="modal-content">
      <div class="modal-header">
        <h4>Confirmation</h4>
      </div>
      <div class="modal-body">
        <p>Bla bla confirm some action?</p>
      </div>
      <div class="modal-footer">
        <button class="btn btn-outline-danger" type="button">Cancel</button>
        <button class="btn btn-primary" type="button">OK</button>
      </div>
    </div>
  </confirm>
    </div>

thanks

from ngx-simple-modal.

kevcjones-archived avatar kevcjones-archived commented on August 14, 2024

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

it is:

<div role="dialog" class="modal fade in" ...
also dialog is not centered

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

there is any fix I can do,for the moment it doesn't work for me even I put this in confirm.component.css

.fade:not(.show) {
    opacity: 1 !important;
}

from ngx-simple-modal.

kevcjones-archived avatar kevcjones-archived commented on August 14, 2024

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

seems putting this code to app style.css seems to work(no invisible):

.fade:not(.show) {
    opacity: 1 !important;
}

but the dialog has screen width,there is a way I can control it?
thanks

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

seems to work with this:

.modal-content {
    margin: 20px auto;
    max-width: 580px;
    position: relative;
    width: 100%;
}

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

Just one last problem and will not annoy you: when I want to close it pressing one of the confirm buttons it took up 1 second to close,there is any way to speed it up?thanks

from ngx-simple-modal.

mrjohnr avatar mrjohnr commented on August 14, 2024

Seems to work fine if I put css in style.css not in component.css:

transition: opacity 1ms linear;

from ngx-simple-modal.

kevcjones-archived avatar kevcjones-archived commented on August 14, 2024

I'll update the readme to make this clearer for other people but the styles are indeed mean't to be loaded globally since you might have more than one modal, its the better place to put them. Leaving your local styles for customisations and modal content only.

from ngx-simple-modal.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.